Uploaded image for project: 'Titanium SDK/CLI'
  1. Titanium SDK/CLI
  2. TIMOB-18477

IOS: A Popover will swallow any OptionDialog created

    Details

    • Type: Bug
    • Status: Open
    • Resolution: Unresolved
    • Affects Version/s: Release 3.5.0
    • Fix Version/s: None
    • Component/s: iOS
    • Environment:

      SDK 3.5.0, iPad

      Description

      When a Popover is opened and attached to one of the window’s rightNavItems and an OptionDialog is opened, the OptionDialog is opened inside the Popover. This does not happen if you open another OptionDialog without closing the one inside the Popover.

      Steps

      1. Click on "options"
      2. Click on "popover"
      3. Click on "options"
      4. Click on "options" again
      5. Click on "options" a third time

      Expected results

      1. the OptionDialog opens (correctly attached to the "options" button)
      2. the Popover opens
      3. another OptionDialog (correctly attached) opens on top of the Popover
      4. the second OptionDialog closes
      5. another OptionDialog (correctly attached) opens on top of the Popover

      Actual result

      1. the OptionDialog opens (correctly attached to the "options" button)
      2. the Popover opens
      3. another OptionDialog opens inside the Popover, as a modal iPhone-esque OptionDialog
      4. another OptionDialog opens (correctly attached to the "options" button)
      5. the last OptionDialog closes

      Attached Code

      var popoverButton = Ti.UI.createButton({ title: 'popover' });
      var optionsButton = Ti.UI.createButton({ title: 'options' });
       
      var window = Ti.UI.createWindow({
      	backgroundColor: 'gray',
      	rightNavButtons: [ popoverButton, optionsButton ]
      });
       
      var navWindow = Ti.UI.iOS.createNavigationWindow({
      	window: window
      });
       
      optionsButton.addEventListener('click', function () {
      	var options = Ti.UI.createOptionDialog({
      		title: 'Options',
      		options: [ 'A', 'B', 'C' ]
      	});
       
      	options.show({ view: optionsButton });
      });
       
      popoverButton.addEventListener('click', function () {
      	var contentView = Ti.UI.createLabel({
      		text: 'this is the content',
      		width: 300,
      		height: 300,
      		textAlign: Ti.UI.TEXT_ALIGNMENT_CENTER
      	});
       
      	var popover = Ti.UI.iPad.createPopover({
      		contentView: contentView
      	});
       
      	popover.show({ view: popoverButton });
      });
       
      navWindow.open();
      

        Attachments

          Issue Links

            Activity

              People

              • Assignee:
                Unassigned
                Reporter:
                yuchi Pier Paolo Ramon
              • Watchers:
                0 Start watching this issue

                Dates

                • Created:
                  Updated:

                  Backbone Issue Sync

                  • Titanium SDK/CLI <> Titanium Mobile
                    Synced with:
                    TIMOB-19665
                    Sync status:
                    ERROR
                    Last received:
                    Last sent:

                    Git Source Code