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

Android: Add Ti.UI.overrideUserInterfaceStyle property

    Details

    • Story Points:
      5

      Description

      Summary:
      We should add a new writable Ti.UI.overrideUserInterfaceStyle property that allows you to force the app to use a dark or light theme instead of using the system assigned theme. If this property is assigned the Ti.UI.USER_INTERFACE_STYLE_UNSPECIFIED constant (the default), then the app will use the system theme instead.

      The existing read-only Ti.UI.userInterfaceStyle property needs to be its own property. If the overrideUserInterfaceStyle is set to unspecified, then the userInterfaceStyle property will reveal if the system is using the dark or light theme.

      Native Implementation:
      On iOS, this can be implemented via the native UIView.overrideUserInterfaceStyle property.

      On Android, this can be implemented via the Java AppCompatDelegate.setNightMode() method.

      Android Example:

        Attachments

          Activity

            People

            • Assignee:
              jquick Joshua Quick
              Reporter:
              jquick Joshua Quick
              Reviewer:
              Gary Mathews
              Tester:
              Samir Mohammed
            • Watchers:
              3 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved:

                Backbone Issue Sync

                • Backbone Issue Sync is enabled for your project, but we do not have any synchronization info for this issue.

                  Git Integration