Titanium JIRA Archive
Titanium SDK/CLI (TIMOB)

[TIMOB-18865] iOS8: Keyboard toolbar not removed when undocking keyboard

GitHub Issuen/a
TypeBug
PriorityHigh
StatusClosed
ResolutionFixed
Resolution Date2015-05-15T21:35:30.000+0000
Affected Version/sRelease 4.0.0
Fix Version/sRelease 4.1.0
ComponentsiOS
Labelsn/a
ReporterEduardo Gomez
AssigneeChee Kiat Ng
Created2015-04-30T22:55:26.000+0000
Updated2015-06-01T22:51:35.000+0000

Description

Steps to reproduce

1) Run sample on iPad Sim/device and hit "Focus to see keyboard w/ toolbar" 2) Undock Keyboard by clicking the icon at bottom right. 3) Events work as expected 4) Hide keyboard, noticed toolbar remains in the middle of screen.

Test Case

var win = Ti.UI.createWindow({
    //title : _args.title
});

win.orientationModes = [Titanium.UI.PORTRAIT, Titanium.UI.UPSIDE_PORTRAIT, Titanium.UI.LANDSCAPE_LEFT, Titanium.UI.LANDSCAPE_RIGHT];

var flexSpace = Titanium.UI.createButton({
    systemButton : Titanium.UI.iPhone.SystemButton.FLEXIBLE_SPACE
});

var tf = Titanium.UI.createTextField({
    height : 32,
    backgroundImage : 'KS_nav_ui.png',
    width : 200,
    font : {
        fontSize : 13
    },
    color : '#777',
    paddingLeft : 10,
    borderStyle : Titanium.UI.INPUT_BORDERSTYLE_NONE
});

var camera = Titanium.UI.createButton({
    backgroundImage : 'KS_nav_views.png',
    height : 33,
    width : 33
});
camera.addEventListener('click', function() {
    Titanium.UI.createAlertDialog({
        title : 'Toolbar',
        message : 'You clicked camera!'
    }).show();
});

var send = Titanium.UI.createButton({
    backgroundImage : 'KS_nav_ui.png',
    backgroundSelectedImage : 'KS_nav_views.png',
    width : 67,
    height : 32
});
send.addEventListener('click', function() {
    Titanium.UI.createAlertDialog({
        title : 'Toolbar',
        message : 'You clicked send!'
    }).show();
});

var textfield = Titanium.UI.createTextField({
    color : '#336699',
    value : 'Focus to see keyboard w/ toolbar',
    height : 35,
    width : 300,
    top : 10,
    borderStyle : Titanium.UI.INPUT_BORDERSTYLE_ROUNDED,
    keyboardToolbar : [flexSpace, camera, flexSpace, tf, flexSpace, send, flexSpace],
    keyboardToolbarColor : '#999',
    keyboardToolbarHeight : 40
});

var textfield2 = Titanium.UI.createTextField({
    color : '#336699',
    value : 'Focus to see keyboard w/o toolbar',
    height : 35,
    width : 300,
    top : 70,
    borderStyle : Titanium.UI.INPUT_BORDERSTYLE_ROUNDED
});

win.add(textfield);
win.add(textfield2);

win.open();

Attachments

FileDateSize
iOS8.2 iPad mini.png2015-05-04T18:56:18.000+0000139993
KeyboardKeys.zip2015-05-05T21:17:12.000+0000110962

Comments

  1. Ingo Muschenetz 2015-05-04

    Need to check if it's a regression.
  2. Eduardo Gomez 2015-05-04

    Not a regression. Attached image from device.
  3. Eduardo Gomez 2015-05-04

    Here is a video showing the issue: http://screencast.com/t/jsfTcLvQc8
  4. Chee Kiat Ng 2015-05-05

    Can we check if it is reproducible natively?
  5. Eduardo Gomez 2015-05-05

    So far I can't reproduce natively.
  6. Chee Kiat Ng 2015-05-14

    PR here: https://github.com/appcelerator/titanium_mobile/pull/6849
  7. Lokesh Choudhary 2015-06-01

    Verified the fix. The toolbar is now removed after undocking keyboard. Closing. Environment: Appc Studio : 4.1.0.201505071004 Ti SDK : 4.1.0.v20150529013634 CLI : 4.0.1 Alloy : 1.6.0 MAC Yosemite : 10.10.3 Appc npm : 4.0.0 Appc CLI : 4.0.1 Node: v0.10.37 Ipad Simulator : Ipad Retina IOS 8.3

JSON Source