[TIMOB-19725] iOS: Toggled action buttons display over keyboard
GitHub Issue | n/a |
---|---|
Type | Bug |
Priority | Medium |
Status | Closed |
Resolution | Fixed |
Resolution Date | 2016-02-06T00:49:11.000+0000 |
Affected Version/s | Release 5.1.0 |
Fix Version/s | Release 5.2.0 |
Components | iOS |
Labels | qe-5.1.0, qe-5.2.0 |
Reporter | Eric Wieber |
Assignee | Angel Petkov |
Created | 2015-10-14T17:40:49.000+0000 |
Updated | 2016-02-06T00:50:23.000+0000 |
Description
When all the action buttons are removed from above the keyboard and a keyboard button is pushed, the bar for the action buttons is hidden. If the action buttons are then toggled back on, they display on top of the keyboard. See attached gif:
!toggleoverlay.gif|thumbnail!
Example code:
var showUndoRedoActionsField = true;
var win = Ti.UI.createWindow({backgroundColor: "#fff",layout: "vertical"});
var field = Ti.UI.createTextArea({width: 300,height: 50,top: 100,backgroundColor: "#f0f0f0",value: "Hello" ,showUndoRedoActions:true});
var btn1 = Ti.UI.createButton({title: "Toggle field"});
field.autocorrect = false;
//field.showUndoRedoActions = showUndoRedoActionsField;
btn1.addEventListener("click", function() {
showUndoRedoActionsField = !showUndoRedoActionsField;
field.showUndoRedoActions = showUndoRedoActionsField;
});
win.add(field);
win.add(btn1);
win.open();
*Steps to reproduce issue*
1. Launch an app using the above code on an iPad
2. Click on the textfield
3. Click the 'Toggle Field' button
4. Click any key on the keyboard
5. Click the 'Toggle Field' button
*Actual Results*
The action buttons are shown on top of the keyboard
*Expected Results*
The action button bar appears and contains the action buttons
*Notes*
This could be an iOS issue
Attachments
File | Date | Size |
---|---|---|
toggleoverlay.gif | 2015-10-14T17:39:10.000+0000 | 132487 |
PR pending https://github.com/appcelerator/titanium_mobile/pull/7499/files.
CR and FT passed. PR Merged. New sample code to test:
Steps to test
test with field property (During creation)showUndoRedoActions
set to true, false, and not setting this property.Upon testing this issue with the latest components, it was found that the demo code can no longer produce the
UndoRedo
actions. A resolution is currently in working progress. Tested on: iPhone 6s Plus Device (9.2) & iPhone 6 Plus Device (8.4) Mac OSX El Capitan 10.11 (15A284) Ti SDK: 5.2.0.v20160114021251 Appc NPM: 4.2.3-1 App CLI: 5.2.0-231 Xcode 7.2 Node v4.2.3 *Reopening Ticket.*Update: Upon initial testing, i did not realise that this feature was an iPad only feature. However, after testing with an iPad pro, receive the following error:
The resolution to this fix is to include the tag in the tiapp.xml:
<run-on-main-thread>true</run-on-main-thread>
underReopening this ticket. As of 5.2.0,
<run-on-main-thread>true</run-on-main-thread>
is not present by default, so this error persists. Tested using: MacOS 10.11.3 (15D21) Studio 4.5.0.201601262138 Ti SDK 5.2.0.v20160202103508 Appc NPM 4.2.3-1 Appc CLI 5.2.0-239 Alloy 1.7.33 Xcode 7.2 (7C68)PR pending : https://github.com/appcelerator/titanium_mobile/pull/7674.
CR and FT passed. Need a 5_2_X back port please.
PR(5_2_X) : https://github.com/appcelerator/titanium_mobile/pull/7678
PRs merged!
Reopening. I no longer encounter the "Only run on main thread" error on iPads. However, like [~htbryant] stated before, the UndoButtons can no longer be toggled. Use the code provided in the ticket body, in a classic app, and try to toggle the buttons. This technically does solve the main issue as you can not toggle the buttons, but is this the intended solution? MacOS 10.11.3 (15D21) Studio 4.5.0.201602050824 Ti SDK 5.2.0.v20160205071936 Appc NPM 4.2.3-1 Appc CLI 5.2.0-247 Alloy 1.7.33 Xcode 7.2 (7C68) iOS 9.2, iPad Pro simulator, iPad Air 2 simulator
Hi, This property can only be set during creation. Please see apidocs.
Thanks [~cng]. In light of that, closing as fixed. Verified with above environment and sample code(s) provided.