DemoUi


Source link: https://github.com/noties/DemoUi

DemoUi

Command line tool to access Android Demo Ui

Modes

This tools has 2 modes:

  • Standart mode, application will evaluate all arguments, apply them and exit
  • Live mode, application starts to listen for supplied arguments and apply them. This mode helps to tweak options and receive fast feedback. To start it use -l argument, to exit from live mode: -le

Configuration

Application supports saving/loading of configurations.

# Loads configuration for a file name `first.demoui` ./demoui -cf first  # Saves current configuration to a filename `second.demoui` ./demoui -cs second 

Configurations can be used with arguments:

./demoui -nwl 3 -cf first 

Here first configuration will be used as a base. All supplied arguments will override base options.

# Loads `first` configuration, applies `-na 1` argument and saves this configuration to `second` ./demoui -cf first -na 1 -cs second 

Application saves/loads only files with .demoui extensions (which can be omitted when typing).

Screenshot

To make a screenshot add -s argument followed by a file name

./demoui -na 1 -s "1.png"  # applies arguments, takes a screenshot and exits from demo mode ./demoui -na 1 -ch 1012 -s "1.png" && demoui -e 

-h, --help

All demo ui options are taken from this document

All options have short and long names

usage: demoui [-a <adb-path>] [-ad | -ae | -as <serial>]
[-bl <level>]

  [-bp <charging>] [-bs <style>] [-cf <file>] [-ch <hhmm> | -cm

  <millis>]  [-cs <file>] [-d <enable>] [-de | -e]  [-h] [-l | -le]

  [-na <show>] [-nc <show>] [-nf <fully>] [-nm <mobile>] [-nmd

  <datatype>] [-nml <level>] [-nns <show>] [-ns <sims>] [-nv <show>]

  [-nw <wifi>] [-nwl <wifi-level>] [-sa <show>] [-sb <status>] [-sda

  <enable>] [-se <show>] [-sl <show>] [-sm <show>] [-ss <show>] [-ssp

  <show>] [-st <show>] [-sv <type>]  -a,--adb-path <adb-path>

 Path to the `adb`

executable, if not provided

adb is considered to be

found in PATH  -ad,--adb-device

Uses physical device as a

target for adb  -ae,--adb-emulator

 Uses emulator as a target

for adb  -as,--adb-serial <serial>

Uses device with serial

number as a target for adb  -bl,--battery-level <level>

 Battery. Sets the battery

level (0 - 100)  -bp,--battery-plugged <charging>

  Battery. Sets charging

state (`1|true` for

charging, everything else

for non-charging)  -bs,--bar-style <style>

  Bars. Control the visual

style of the bars

([o]paque, [t]ranslucent,

[s]emi-transparent)  -cf,--configuration-file <file>

Loads demo configuration

from a file  -ch,--clock-hhmm <hhmm>

  Clock. Sets the time in

`hhmm`  -cm,--clock-millis <millis>

 Clock. Sets the time in

millis  -cs,--configuration-save <file>

Saves current demo

configuration  -d,--debug <enable>

`1|true` enables printing

of adb executed commands,

everything else disables  -de,--enter

  Enters demo mode, bar state

allowed to be modified (for

convenience, any of the

other non-exit commands

will automatically flip

demo mode on, no need to

call this explicitly in

practice)  -e,--exit

 Exits demo mode, bars back

to their system-driven

state  -h,--help

 Prints help  -l,--live

 Enters `live` mode  -le,--live-exit

 Exits `live` mode  -na,--network-airplane <show>

  Network. `1|true` to show

icon, any other value to

hide  -nc,--network-carrier-network-change <show>
Network. Sets mobile signal

icon to carrier network

change UX when disconnected

(`1|true` to show icon, any

other value to hide)  -nf,--network-fully <fully>

 Network. Sets MCS state to

fully connected (`1|true`

for true, everything else

for false)  -nm,--network-mobile <mobile>

  Network. `1|true` to show

mobile icon, any other

value to hide  -nmd,--network-mobile-datatype <datatype>
  Network. Values: `1x`,

`3g`, `4g`, `e`, `g`, `h`,

`lte`, `roam`, any other

value to hide  -nml,--network-mobile-level <level>

  Network. Sets mobile signal

strength level (0-4)  -nns,--network-no-sim <show>

Network. `1|true` to show

no-sim icon, any other

value to hide  -ns,--network-sims <sims>

Network. Sets the number of

sims (1-8)  -nv,--notifications-hide <show>

Notifications. `0|false` to

hide the notification

icons, any other value to

show  -nw,--network-wifi <wifi>

Network. `1|true` to show

wifi icon, any other value

to hide  -nwl,--network-wifi-level <wifi-level>

  Network. Sets wifi level

(0-4)  -sa,--status-alarm <show>

Status. Sets the icon in

the alarm_clock slot

(`1|true` to show, any

other value to hide)  -sb,--status-bluetooth <status>

Status. Sets the icon in

the bluetooth slot

([c]onnected,

[d]isconnected, any other

value to hide)  -sda,--sysui-demo-allowed <enable>

Modifies global

`sysui_demo_allowed` state,

`1|true` to enable,

everything else to disable  -se,--status-eri <show>

  Status. Sets the icon in

the cdma_eri slot (`1|true`

to show, any other value to

hide)  -sl,--status-location <show>

Status. Sets the icon in

the location slot (`1|true`

to show, any other value to

hide)  -sm,--status-mute <show>

 Status. Sets the icon in

the mute slot (`1|true` to

show, any other value to

hide)  -ss,--status-sync <show>

 Status. Sets the icon in

the sync_active slot

(`1|true` to show, any

other value to hide)  -ssp,--status-speakerphone <show>

 Status. Sets the icon in

the speakerphone slot

(`1|true` to show, any

other value to hide)  -st,--status-tty <show>

  Status. Sets the icon in

the tty slot (`1|true` to

show, any other value to

hide)  -sv,--status-volume <type>

  Status. Sets the icon in

the volume slot ([s]ilent,

[v]ibrate, any other value

to hide)

License

  Copyright 2017 Dimitry Ivanov ([email protected])
 Licensed under the Apache License, Version 2.0 (the "License");

you may not use this file except in compliance with the License.
You may obtain a copy of the License at

  http://www.apache.org/licenses/LICENSE-2.0
 Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License. 

Resources

Simple way to filter your ListView or GridView content.

Easy SharedPreference Engine foR ANDROid.

This is a simple Android utils library to write any type of data into cache files and then read them later, using Gson to serialize and deserialize these data.

An Android Library for the type-safe creation of Share Intents.

Library for Emoji View like Hangouts, Emoji TextView and Emoji EditText.

VisibilityPercentageLayout is a layout (extends RelativeLayout) with a custom listener which gives the visibility percentage of the layout every time it is changed.Pixel visibility listener is also available.

Topics


2D Engines   3D Engines   9-Patch   Action Bars   Activities   ADB   Advertisements   Analytics   Animations   ANR   AOP   API   APK   APT   Architecture   Audio   Autocomplete   Background Processing   Backward Compatibility   Badges   Bar Codes   Benchmarking   Bitmaps   Bluetooth   Blur Effects   Bread Crumbs   BRMS   Browser Extensions   Build Systems   Bundles   Buttons   Caching   Camera   Canvas   Cards   Carousels   Changelog   Checkboxes   Cloud Storages   Color Analysis   Color Pickers   Colors   Comet/Push   Compass Sensors   Conferences   Content Providers   Continuous Integration   Crash Reports   Credit Cards   Credits   CSV   Curl/Flip   Data Binding   Data Generators   Data Structures   Database   Database Browsers   Date &   Debugging   Decompilers   Deep Links   Dependency Injections   Design   Design Patterns   Dex   Dialogs   Distributed Computing   Distribution Platforms   Download Managers   Drawables   Emoji   Emulators   EPUB   Equalizers &   Event Buses   Exception Handling   Face Recognition   Feedback &   File System   File/Directory   Fingerprint   Floating Action   Fonts   Forms   Fragments   FRP   FSM   Functional Programming   Gamepads   Games   Geocaching   Gestures   GIF   Glow Pad   Gradle Plugins   Graphics   Grid Views   Highlighting   HTML   HTTP Mocking   Icons   IDE   IDE Plugins   Image Croppers   Image Loaders   Image Pickers   Image Processing   Image Views   Instrumentation   Intents   Job Schedulers   JSON   Keyboard   Kotlin   Layouts   Library Demos   List View   List Views   Localization   Location   Lock Patterns   Logcat   Logging   Mails   Maps   Markdown   Mathematics   Maven Plugins   MBaaS   Media   Menus   Messaging   MIME   Mobile Web   Native Image   Navigation   NDK   Networking   NFC   NoSQL   Number Pickers   OAuth   Object Mocking   OCR Engines   OpenGL   ORM   Other Pickers   Parallax List   Parcelables   Particle Systems   Password Inputs   PDF   Permissions   Physics Engines   Platforms   Plugin Frameworks   Preferences   Progress Indicators   ProGuard   Properties   Protocol Buffer   Pull To   Purchases   Push/Pull   QR Codes   Quick Return   Radio Buttons   Range Bars   Ratings   Recycler Views   Resources   REST   Ripple Effects   RSS   Screenshots   Scripting   Scroll Views   SDK   Search Inputs   Security   Sensors   Services   Showcase Views   Signatures   Sliding Panels   Snackbars   SOAP   Social Networks   Spannable   Spinners   Splash Screens   SSH   Static Analysis   Status Bars   Styling   SVG   System   Tags   Task Managers   TDD &   Template Engines   Testing   Testing Tools   Text Formatting   Text Views   Text Watchers   Text-to   Toasts   Toolkits For   Tools   Tooltips   Trainings   TV   Twitter   Updaters   USB   User Stories   Utils   Validation   Video   View Adapters   View Pagers   Views   Watch Face   Wearable Data   Wearables   Weather   Web Tools   Web Views   WebRTC   WebSockets   Wheel Widgets   Wi-Fi   Widgets   Windows   Wizards   XML   XMPP   YAML   ZIP Codes