Titanium JIRA Archive
Alloy (ALOY)

[ALOY-949] Customizable properties for dialogs bultin

GitHub Issuen/a
TypeImprovement
PriorityLow
StatusClosed
ResolutionFixed
Resolution Date2014-05-21T19:42:00.000+0000
Affected Version/sn/a
Fix Version/sAlloy 1.4.0, 2014 Sprint 03
ComponentsBuiltins
Labelsqe-testadded
ReporterTony Lukasavage
AssigneeFeon Sua Xin Miao
Created2014-02-05T15:14:14.000+0000
Updated2014-05-22T18:45:42.000+0000

Description

We should be able to customize the title, message, and buttonNames of the AlertDialog created by dialogs.confirm(). While this can be done on each call of confirm() it would be nice to be able to set the default value.

Attachments

FileDateSize
dialogs_FedeTest.png2014-05-10T01:44:50.000+000030637
iOS Simulator Screen shot Feb 5, 2014, 10.27.53 AM.png2014-02-05T15:39:35.000+000041042
iOS Simulator Screen shot Feb 5, 2014, 10.28.01 AM.png2014-02-05T15:39:35.000+000044084
iOS Simulator Screen shot Feb 5, 2014, 10.28.07 AM.png2014-02-05T15:39:35.000+000046043
iOS Simulator Screen shot Feb 5, 2014, 10.31.30 AM.png2014-02-05T15:39:35.000+000044258

Comments

  1. Tony Lukasavage 2014-02-05

    PR: https://github.com/appcelerator/alloy/pull/325 test app: https://github.com/appcelerator/alloy/tree/master/test/apps/testing/ALOY-949 Function test:

    run test app

    click the right button on each dialog that pops up (yes, yup, fo shizzle)

    Confirm that the 4 dialogs you see appear as the attached screenshots do, and in that oder. (screenshots from ios sim)

  2. Federico Casali 2014-05-10

    Reopened. Running on both Android and iOS I'm noticing an issue setting the 'buttonName' using dialogs.confirm(). From my test,
       buttonNames: ['Nope', 'Yup'],
       
    is not set, so the button names are the ones set in the previous dialog. For example, with the given test sample, the third displayed dialog would show "'Naaah - Fo shizzle" instead of "Nope - Yup" buttons. Attached screenshot ("dialogs_FedeTest")
       title: 'Confirm (args)',
       message: 'Are the args working?',
       
    Seems to be applied correctly, as well as the callback, triggering the right function.

    Environment:

    TiSDK 3.3.0.v20140509104912 Alloy 1.4.0-dev Appcelerator Studio 3.3.0.201405011408 CLI 3.3.0-dev
  3. Feon Sua Xin Miao 2014-05-13

    PR: https://github.com/appcelerator/alloy/pull/394 Test App: https://github.com/feons/alloy/tree/ALOY-949/test/apps/testing/ALOY-949 Function Test: Click the right button on each dialog that pops up, the test app will show 5 dialogs. The right button name sequence is : Yes, Fo shizzle, Yup, Yeah, Fo shizzle
  4. Tim Poulsen 2014-05-13

    None of the buttons are clickable for me, I suspect because of TIMOB-16656. I've linked that ticket as blocking this one. I'm glad to revisit if there's a way to get this working so I can test your pull request.
  5. Ingo Muschenetz 2014-05-19

    Re-resolving based on comments.
  6. Tim Poulsen 2014-05-21

    Tested on iOS, Android, and MobileWeb. All work as expected (with the caveat that MobileWeb requires 3.3.0 alpha because of the button-click issue with the SDK) PR merged
  7. Federico Casali 2014-05-22

    Checked verified fixed. Closing. TiSDK 3.3.0.v20140521174951 Alloy 1.4.0-alpha4 Appcelerator Studio 3.3.0.201405211748 CLI 3.3.0-alpha5

JSON Source