-
mihir77Likes 0Problem Description
Hi,
This is my code for textfield –
auto emailField = TextField::create("Email", "Arial", 30);
emailField->setPosition(Vec2(origin.x + visibleSize.width/2,
origin.y + visibleSize.height/2));
emailField->ignoreContentAdaptWithSize(false);
emailField->setSize(Size(240, 160));
emailField->setMaxLength(50);
emailField->setMaxLengthEnabled(true);
emailField->setColor(Color3B(0, 0, 0));
emailField->setTextHorizontalAlignment(TextHAlignment::LEFT);
emailField->setTextVerticalAlignment(TextVAlignment::CENTER);
emailField->setTouchEnabled(true);
emailField->addTouchEventListener([&](Ref* psender, Widget::TouchEventType type){
log(“typing”);
});In cocos2d-x 3.4, it used to show keypad when touched on textfield, now i updated to cocos2d-x 3.8.1 and it doesn't show keypad.
Do i need to add something or modify something?
-
Sonar Systems adminLikes 0
What device are you using?
-
mihir77Likes 0
I am running in xcode simulator..
-
Sonar Systems adminLikes 0
On simulator it can be dodgy, try on a physical device and it should be all good.
Login to reply