├── .idea
├── .name
├── copyright
│ └── profiles_settings.xml
├── encodings.xml
├── vcs.xml
├── modules.xml
├── runConfigurations.xml
├── gradle.xml
├── compiler.xml
└── misc.xml
├── app
├── .gitignore
├── src
│ ├── main
│ │ ├── res
│ │ │ ├── drawable
│ │ │ │ ├── watch.png
│ │ │ │ ├── header.png
│ │ │ │ ├── button_up.png
│ │ │ │ ├── watch_back.png
│ │ │ │ ├── button_back.png
│ │ │ │ ├── button_down.png
│ │ │ │ ├── button_select.png
│ │ │ │ └── row_selector.xml
│ │ │ ├── drawable-hdpi
│ │ │ │ ├── ic_add.png
│ │ │ │ ├── ic_exit.png
│ │ │ │ ├── ic_play.png
│ │ │ │ ├── ic_stop.png
│ │ │ │ ├── tile.9.png
│ │ │ │ ├── ic_delete.png
│ │ │ │ ├── ic_forward.png
│ │ │ │ ├── ic_preview.png
│ │ │ │ ├── ic_refresh.png
│ │ │ │ ├── ic_tools.png
│ │ │ │ ├── ic_upload.png
│ │ │ │ ├── ic_watch.png
│ │ │ │ ├── ic_download.png
│ │ │ │ ├── ic_extension.png
│ │ │ │ ├── ic_launcher.png
│ │ │ │ ├── ic_settings.png
│ │ │ │ ├── ic_watch_off.png
│ │ │ │ ├── ic_watchface.png
│ │ │ │ ├── ic_categorize.png
│ │ │ │ ├── ic_watch_dial.png
│ │ │ │ ├── ic_crop_free_black_48dp.png
│ │ │ │ └── ic_file_upload_black_18dp.png
│ │ │ ├── drawable-mdpi
│ │ │ │ ├── ic_add.png
│ │ │ │ ├── ic_exit.png
│ │ │ │ ├── ic_play.png
│ │ │ │ ├── ic_stop.png
│ │ │ │ ├── ic_delete.png
│ │ │ │ ├── ic_forward.png
│ │ │ │ ├── ic_preview.png
│ │ │ │ ├── ic_refresh.png
│ │ │ │ ├── ic_tools.png
│ │ │ │ ├── ic_upload.png
│ │ │ │ ├── ic_watch.png
│ │ │ │ ├── ic_download.png
│ │ │ │ ├── ic_extension.png
│ │ │ │ ├── ic_launcher.png
│ │ │ │ ├── ic_settings.png
│ │ │ │ ├── ic_watch_off.png
│ │ │ │ ├── ic_watchface.png
│ │ │ │ ├── ic_categorize.png
│ │ │ │ ├── ic_watch_dial.png
│ │ │ │ ├── ic_crop_free_black_48dp.png
│ │ │ │ └── ic_file_upload_black_18dp.png
│ │ │ ├── drawable-xhdpi
│ │ │ │ ├── ic_add.png
│ │ │ │ ├── ic_delete.png
│ │ │ │ ├── ic_exit.png
│ │ │ │ ├── ic_play.png
│ │ │ │ ├── ic_stop.png
│ │ │ │ ├── ic_tools.png
│ │ │ │ ├── ic_upload.png
│ │ │ │ ├── ic_watch.png
│ │ │ │ ├── ic_download.png
│ │ │ │ ├── ic_forward.png
│ │ │ │ ├── ic_launcher.png
│ │ │ │ ├── ic_preview.png
│ │ │ │ ├── ic_refresh.png
│ │ │ │ ├── ic_settings.png
│ │ │ │ ├── ic_categorize.png
│ │ │ │ ├── ic_extension.png
│ │ │ │ ├── ic_watch_dial.png
│ │ │ │ ├── ic_watch_off.png
│ │ │ │ ├── ic_watchface.png
│ │ │ │ ├── ic_crop_free_black_48dp.png
│ │ │ │ └── ic_file_upload_black_18dp.png
│ │ │ ├── drawable-xxhdpi
│ │ │ │ ├── ic_add.png
│ │ │ │ ├── ic_exit.png
│ │ │ │ ├── ic_play.png
│ │ │ │ ├── ic_stop.png
│ │ │ │ ├── ic_tools.png
│ │ │ │ ├── ic_watch.png
│ │ │ │ ├── ic_delete.png
│ │ │ │ ├── ic_forward.png
│ │ │ │ ├── ic_preview.png
│ │ │ │ ├── ic_refresh.png
│ │ │ │ ├── ic_upload.png
│ │ │ │ ├── ic_categorize.png
│ │ │ │ ├── ic_download.png
│ │ │ │ ├── ic_extension.png
│ │ │ │ ├── ic_launcher.png
│ │ │ │ ├── ic_settings.png
│ │ │ │ ├── ic_watch_dial.png
│ │ │ │ ├── ic_watch_off.png
│ │ │ │ ├── ic_watchface.png
│ │ │ │ ├── ic_crop_free_black_48dp.png
│ │ │ │ └── ic_file_upload_black_18dp.png
│ │ │ ├── drawable-hdpi-v9
│ │ │ │ ├── ic_watch_off.png
│ │ │ │ └── ic_watch_dial.png
│ │ │ ├── drawable-mdpi-v9
│ │ │ │ ├── ic_watch_off.png
│ │ │ │ └── ic_watch_dial.png
│ │ │ ├── drawable-xxxhdpi
│ │ │ │ ├── ic_launcher.png
│ │ │ │ ├── ic_crop_free_black_48dp.png
│ │ │ │ └── ic_file_upload_black_18dp.png
│ │ │ ├── drawable-hdpi-v11
│ │ │ │ ├── ic_watch_dial.png
│ │ │ │ └── ic_watch_off.png
│ │ │ ├── drawable-mdpi-v11
│ │ │ │ ├── ic_watch_dial.png
│ │ │ │ └── ic_watch_off.png
│ │ │ ├── drawable-xhdpi-v11
│ │ │ │ ├── ic_watch_off.png
│ │ │ │ └── ic_watch_dial.png
│ │ │ ├── drawable-xhdpi-v9
│ │ │ │ ├── ic_watch_dial.png
│ │ │ │ └── ic_watch_off.png
│ │ │ ├── drawable-xxhdpi-v9
│ │ │ │ ├── ic_watch_off.png
│ │ │ │ └── ic_watch_dial.png
│ │ │ ├── drawable-xxhdpi-v11
│ │ │ │ ├── ic_watch_dial.png
│ │ │ │ └── ic_watch_off.png
│ │ │ ├── values-hdpi
│ │ │ │ └── dimens.xml
│ │ │ ├── values-mdpi
│ │ │ │ └── dimens.xml
│ │ │ ├── values-xhdpi
│ │ │ │ └── dimens.xml
│ │ │ ├── values-xxhdpi
│ │ │ │ └── dimens.xml
│ │ │ ├── layout
│ │ │ │ ├── toolbar_default.xml
│ │ │ │ ├── pref_switch.xml
│ │ │ │ ├── pref_image_play.xml
│ │ │ │ ├── drawer_header.xml
│ │ │ │ ├── fragment_plugins.xml
│ │ │ │ ├── fragment_watchsets.xml
│ │ │ │ ├── fragment_watches.xml
│ │ │ │ ├── activity_watch_set_preview.xml
│ │ │ │ ├── activity_settings.xml
│ │ │ │ ├── listitem_plugin.xml
│ │ │ │ ├── listitem_watchset.xml
│ │ │ │ ├── listitem_device.xml
│ │ │ │ ├── time_interval_dialog.xml
│ │ │ │ └── activity_main.xml
│ │ │ ├── values-w820dp
│ │ │ │ └── dimens.xml
│ │ │ ├── anim
│ │ │ │ ├── slide_in.xml
│ │ │ │ └── slide_out.xml
│ │ │ ├── values
│ │ │ │ ├── dimens.xml
│ │ │ │ ├── colors.xml
│ │ │ │ ├── template-dimens.xml
│ │ │ │ ├── base-strings.xml
│ │ │ │ └── arrays.xml
│ │ │ ├── values-sw600dp
│ │ │ │ └── template-dimens.xml
│ │ │ ├── values-v21
│ │ │ │ └── base-template-styles.xml
│ │ │ └── menu
│ │ │ │ ├── scan.xml
│ │ │ │ ├── import_watchset.xml
│ │ │ │ ├── gatt_services.xml
│ │ │ │ ├── drawer_view.xml
│ │ │ │ └── watchsets.xml
│ │ └── java
│ │ │ └── com
│ │ │ └── althink
│ │ │ └── android
│ │ │ └── ossw
│ │ │ ├── emulator
│ │ │ ├── event
│ │ │ │ ├── EmulatorEvent.java
│ │ │ │ ├── EmulatorButton.java
│ │ │ │ ├── ButtonPressedEmulatorEvent.java
│ │ │ │ ├── ButtonLongPressedEmulatorEvent.java
│ │ │ │ └── AbstractButtonEmulatorEvent.java
│ │ │ ├── fonts
│ │ │ │ ├── EmulatorFont.java
│ │ │ │ ├── CharInfo.java
│ │ │ │ ├── CharInfoLookup.java
│ │ │ │ └── FontInfo.java
│ │ │ ├── source
│ │ │ │ ├── EmulatorResourceSource.java
│ │ │ │ ├── converter
│ │ │ │ │ ├── EmulatorDataConverter.java
│ │ │ │ │ ├── MockConverter.java
│ │ │ │ │ ├── OnesConverter.java
│ │ │ │ │ ├── TensConverter.java
│ │ │ │ │ ├── HundredsConverter.java
│ │ │ │ │ ├── TimeToHour24Converter.java
│ │ │ │ │ ├── TimeToSecondsConverter.java
│ │ │ │ │ ├── TimeToMinutesConverter.java
│ │ │ │ │ ├── Hour24ToHour12Converter.java
│ │ │ │ │ ├── Hour24ToHour12PeriodConverter.java
│ │ │ │ │ ├── TimeToRoundedHour24Converter.java
│ │ │ │ │ ├── TimeToFiveMinutesRoundedTimeConverter.java
│ │ │ │ │ ├── MinutesToPastToMinutesConverter.java
│ │ │ │ │ └── MinutesToPastToDesignatorConverter.java
│ │ │ │ ├── EmulatorDataSource.java
│ │ │ │ ├── internal
│ │ │ │ │ ├── ZeroDataSource.java
│ │ │ │ │ ├── MacAddressInternalEmulatorDataSource.java
│ │ │ │ │ ├── FirmwareVersionInternalEmulatorDataSource.java
│ │ │ │ │ ├── BatteryLevelInternalEmulatorDataSource.java
│ │ │ │ │ ├── YearInternalEmulatorDataSource.java
│ │ │ │ │ ├── MonthInternalEmulatorDataSource.java
│ │ │ │ │ ├── Hour24InternalEmulatorDataSource.java
│ │ │ │ │ ├── MinutesInternalEmulatorDataSource.java
│ │ │ │ │ ├── SecondsInternalEmulatorDataSource.java
│ │ │ │ │ ├── DayOfWeekInternalEmulatorDataSource.java
│ │ │ │ │ ├── DayOfYearInternalEmulatorDataSource.java
│ │ │ │ │ ├── DayOfMonthInternalEmulatorDataSource.java
│ │ │ │ │ ├── Hour12DesignatorInternalEmulatorDataSource.java
│ │ │ │ │ ├── Hour12InternalEmulatorDataSource.java
│ │ │ │ │ └── TimeInSecondsInternalEmulatorDataSource.java
│ │ │ │ ├── EmulatorAttachedResourceSource.java
│ │ │ │ ├── EmulatorModelDataSource.java
│ │ │ │ ├── EmulatorConvertedDataSource.java
│ │ │ │ ├── StaticDataSource.java
│ │ │ │ └── ExternalEmulatorDataSource.java
│ │ │ ├── actions
│ │ │ │ ├── EmulatorAction.java
│ │ │ │ ├── EmulatorEventHandler.java
│ │ │ │ ├── EmulatorCompoundAction.java
│ │ │ │ ├── EmulatorChooseAction.java
│ │ │ │ ├── SimpleEmulatorAction.java
│ │ │ │ └── EmulatorModelAction.java
│ │ │ ├── renderer
│ │ │ │ ├── ScreenRender.java
│ │ │ │ ├── EmulatorExecutionContext.java
│ │ │ │ └── WatchSetRenderer.java
│ │ │ ├── control
│ │ │ │ ├── EmulatorControl.java
│ │ │ │ ├── digits
│ │ │ │ │ ├── DigitsRenderer.java
│ │ │ │ │ ├── NumbersFontRenderer.java
│ │ │ │ │ └── GeneratedDigits.java
│ │ │ │ ├── AbstractEmulatorControl.java
│ │ │ │ ├── ImageEmulatorControl.java
│ │ │ │ ├── TextEmulatorControl.java
│ │ │ │ ├── ChooseEmulatorControl.java
│ │ │ │ ├── ImageFromSetEmulatorControl.java
│ │ │ │ └── ProgressEmulatorControl.java
│ │ │ ├── model
│ │ │ │ └── EmulatorModelProperty.java
│ │ │ ├── watchset
│ │ │ │ └── WatchSetScreenEmulatorModel.java
│ │ │ └── WatchEmulator.java
│ │ │ ├── UploadDataType.java
│ │ │ ├── watchsets
│ │ │ ├── WatchSetType.java
│ │ │ ├── ValueResolver.java
│ │ │ ├── UtilitiesFragment.java
│ │ │ ├── WatchFacesFragment.java
│ │ │ ├── ApplicationsFragment.java
│ │ │ ├── DataSourceType.java
│ │ │ ├── KnownParseError.java
│ │ │ ├── DataSourceResolutionContext.java
│ │ │ ├── field
│ │ │ │ ├── FieldDefinition.java
│ │ │ │ ├── IntegerFieldDefinition.java
│ │ │ │ └── EnumFieldDefinition.java
│ │ │ ├── EnumToIntResolver.java
│ │ │ ├── ScreenContext.java
│ │ │ ├── CompiledWatchSet.java
│ │ │ └── WatchSetPreviewActivity.java
│ │ │ ├── plugins
│ │ │ ├── PluginPropertyType.java
│ │ │ ├── PluginFunctionDefinition.java
│ │ │ ├── PluginPropertyDefinition.java
│ │ │ └── PluginDefinition.java
│ │ │ ├── notifications
│ │ │ ├── NotificationHandler.java
│ │ │ ├── message
│ │ │ │ ├── NotificationMessageBuilder.java
│ │ │ │ ├── NotificationSummaryMessageBuilder.java
│ │ │ │ ├── AlertNotificationMessageBuilder.java
│ │ │ │ ├── SimpleNotificationMessageBuilder.java
│ │ │ │ ├── ListNotificationMessageBuilder.java
│ │ │ │ └── AbstractNotificationMessageBuilder.java
│ │ │ ├── parser
│ │ │ │ ├── api18
│ │ │ │ │ ├── MessageParser.java
│ │ │ │ │ ├── NotificationType.java
│ │ │ │ │ ├── MessageInfo.java
│ │ │ │ │ ├── DefaultTicker.java
│ │ │ │ │ ├── Message.java
│ │ │ │ │ ├── NotificationParser.java
│ │ │ │ │ ├── DefaultView.java
│ │ │ │ │ └── MessageStore.java
│ │ │ │ └── NotificationIdBuilder.java
│ │ │ └── model
│ │ │ │ ├── NotificationType.java
│ │ │ │ ├── NotificationCategory.java
│ │ │ │ ├── SimpleListItem.java
│ │ │ │ ├── Notification.java
│ │ │ │ ├── Operation.java
│ │ │ │ ├── SubjectMessageItem.java
│ │ │ │ ├── SimpleNotification.java
│ │ │ │ ├── ListNotification.java
│ │ │ │ └── AbstractNotification.java
│ │ │ ├── service
│ │ │ ├── ble
│ │ │ │ ├── ReadCharacteristicHandler.java
│ │ │ │ ├── BleConnectionStatusHandler.java
│ │ │ │ ├── CharacteristicChangeHandler.java
│ │ │ │ └── BleConnectionStatus.java
│ │ │ ├── WatchOperationContext.java
│ │ │ ├── ExternalServiceConnection.java
│ │ │ ├── WatchExtensionProperty.java
│ │ │ └── WatchExtensionFunction.java
│ │ │ ├── utils
│ │ │ ├── StringNormalizer.java
│ │ │ └── FunctionHandler.java
│ │ │ ├── db
│ │ │ └── WatchSetInfo.java
│ │ │ └── settings
│ │ │ ├── TextSwitchPreference.java
│ │ │ └── TimeIntervalPreference.java
│ └── androidTest
│ │ └── java
│ │ └── com
│ │ └── althink
│ │ └── android
│ │ └── ossw
│ │ └── ApplicationTest.java
├── proguard-rules.pro
└── build.gradle
├── settings.gradle
├── gradle
└── wrapper
│ ├── gradle-wrapper.jar
│ └── gradle-wrapper.properties
├── .gitignore
├── .travis.yml
├── gradle.properties
├── ossw-android.iml
└── gradlew.bat
/.idea/.name:
--------------------------------------------------------------------------------
1 | ossw-android
--------------------------------------------------------------------------------
/app/.gitignore:
--------------------------------------------------------------------------------
1 | /build
2 |
--------------------------------------------------------------------------------
/settings.gradle:
--------------------------------------------------------------------------------
1 | include ':app'
2 |
3 |
--------------------------------------------------------------------------------
/.idea/copyright/profiles_settings.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
--------------------------------------------------------------------------------
/app/src/main/res/drawable/watch.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ossw/ossw-android/HEAD/app/src/main/res/drawable/watch.png
--------------------------------------------------------------------------------
/gradle/wrapper/gradle-wrapper.jar:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ossw/ossw-android/HEAD/gradle/wrapper/gradle-wrapper.jar
--------------------------------------------------------------------------------
/app/src/main/res/drawable/header.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ossw/ossw-android/HEAD/app/src/main/res/drawable/header.png
--------------------------------------------------------------------------------
/app/src/main/res/drawable/button_up.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ossw/ossw-android/HEAD/app/src/main/res/drawable/button_up.png
--------------------------------------------------------------------------------
/app/src/main/res/drawable/watch_back.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ossw/ossw-android/HEAD/app/src/main/res/drawable/watch_back.png
--------------------------------------------------------------------------------
/app/src/main/res/drawable-hdpi/ic_add.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ossw/ossw-android/HEAD/app/src/main/res/drawable-hdpi/ic_add.png
--------------------------------------------------------------------------------
/app/src/main/res/drawable-hdpi/ic_exit.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ossw/ossw-android/HEAD/app/src/main/res/drawable-hdpi/ic_exit.png
--------------------------------------------------------------------------------
/app/src/main/res/drawable-hdpi/ic_play.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ossw/ossw-android/HEAD/app/src/main/res/drawable-hdpi/ic_play.png
--------------------------------------------------------------------------------
/app/src/main/res/drawable-hdpi/ic_stop.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ossw/ossw-android/HEAD/app/src/main/res/drawable-hdpi/ic_stop.png
--------------------------------------------------------------------------------
/app/src/main/res/drawable-hdpi/tile.9.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ossw/ossw-android/HEAD/app/src/main/res/drawable-hdpi/tile.9.png
--------------------------------------------------------------------------------
/app/src/main/res/drawable-mdpi/ic_add.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ossw/ossw-android/HEAD/app/src/main/res/drawable-mdpi/ic_add.png
--------------------------------------------------------------------------------
/app/src/main/res/drawable-mdpi/ic_exit.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ossw/ossw-android/HEAD/app/src/main/res/drawable-mdpi/ic_exit.png
--------------------------------------------------------------------------------
/app/src/main/res/drawable-mdpi/ic_play.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ossw/ossw-android/HEAD/app/src/main/res/drawable-mdpi/ic_play.png
--------------------------------------------------------------------------------
/app/src/main/res/drawable-mdpi/ic_stop.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ossw/ossw-android/HEAD/app/src/main/res/drawable-mdpi/ic_stop.png
--------------------------------------------------------------------------------
/app/src/main/res/drawable-xhdpi/ic_add.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ossw/ossw-android/HEAD/app/src/main/res/drawable-xhdpi/ic_add.png
--------------------------------------------------------------------------------
/app/src/main/res/drawable/button_back.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ossw/ossw-android/HEAD/app/src/main/res/drawable/button_back.png
--------------------------------------------------------------------------------
/app/src/main/res/drawable/button_down.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ossw/ossw-android/HEAD/app/src/main/res/drawable/button_down.png
--------------------------------------------------------------------------------
/app/src/main/res/drawable-hdpi/ic_delete.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ossw/ossw-android/HEAD/app/src/main/res/drawable-hdpi/ic_delete.png
--------------------------------------------------------------------------------
/app/src/main/res/drawable-hdpi/ic_forward.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ossw/ossw-android/HEAD/app/src/main/res/drawable-hdpi/ic_forward.png
--------------------------------------------------------------------------------
/app/src/main/res/drawable-hdpi/ic_preview.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ossw/ossw-android/HEAD/app/src/main/res/drawable-hdpi/ic_preview.png
--------------------------------------------------------------------------------
/app/src/main/res/drawable-hdpi/ic_refresh.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ossw/ossw-android/HEAD/app/src/main/res/drawable-hdpi/ic_refresh.png
--------------------------------------------------------------------------------
/app/src/main/res/drawable-hdpi/ic_tools.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ossw/ossw-android/HEAD/app/src/main/res/drawable-hdpi/ic_tools.png
--------------------------------------------------------------------------------
/app/src/main/res/drawable-hdpi/ic_upload.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ossw/ossw-android/HEAD/app/src/main/res/drawable-hdpi/ic_upload.png
--------------------------------------------------------------------------------
/app/src/main/res/drawable-hdpi/ic_watch.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ossw/ossw-android/HEAD/app/src/main/res/drawable-hdpi/ic_watch.png
--------------------------------------------------------------------------------
/app/src/main/res/drawable-mdpi/ic_delete.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ossw/ossw-android/HEAD/app/src/main/res/drawable-mdpi/ic_delete.png
--------------------------------------------------------------------------------
/app/src/main/res/drawable-mdpi/ic_forward.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ossw/ossw-android/HEAD/app/src/main/res/drawable-mdpi/ic_forward.png
--------------------------------------------------------------------------------
/app/src/main/res/drawable-mdpi/ic_preview.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ossw/ossw-android/HEAD/app/src/main/res/drawable-mdpi/ic_preview.png
--------------------------------------------------------------------------------
/app/src/main/res/drawable-mdpi/ic_refresh.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ossw/ossw-android/HEAD/app/src/main/res/drawable-mdpi/ic_refresh.png
--------------------------------------------------------------------------------
/app/src/main/res/drawable-mdpi/ic_tools.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ossw/ossw-android/HEAD/app/src/main/res/drawable-mdpi/ic_tools.png
--------------------------------------------------------------------------------
/app/src/main/res/drawable-mdpi/ic_upload.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ossw/ossw-android/HEAD/app/src/main/res/drawable-mdpi/ic_upload.png
--------------------------------------------------------------------------------
/app/src/main/res/drawable-mdpi/ic_watch.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ossw/ossw-android/HEAD/app/src/main/res/drawable-mdpi/ic_watch.png
--------------------------------------------------------------------------------
/app/src/main/res/drawable-xhdpi/ic_delete.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ossw/ossw-android/HEAD/app/src/main/res/drawable-xhdpi/ic_delete.png
--------------------------------------------------------------------------------
/app/src/main/res/drawable-xhdpi/ic_exit.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ossw/ossw-android/HEAD/app/src/main/res/drawable-xhdpi/ic_exit.png
--------------------------------------------------------------------------------
/app/src/main/res/drawable-xhdpi/ic_play.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ossw/ossw-android/HEAD/app/src/main/res/drawable-xhdpi/ic_play.png
--------------------------------------------------------------------------------
/app/src/main/res/drawable-xhdpi/ic_stop.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ossw/ossw-android/HEAD/app/src/main/res/drawable-xhdpi/ic_stop.png
--------------------------------------------------------------------------------
/app/src/main/res/drawable-xhdpi/ic_tools.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ossw/ossw-android/HEAD/app/src/main/res/drawable-xhdpi/ic_tools.png
--------------------------------------------------------------------------------
/app/src/main/res/drawable-xhdpi/ic_upload.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ossw/ossw-android/HEAD/app/src/main/res/drawable-xhdpi/ic_upload.png
--------------------------------------------------------------------------------
/app/src/main/res/drawable-xhdpi/ic_watch.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ossw/ossw-android/HEAD/app/src/main/res/drawable-xhdpi/ic_watch.png
--------------------------------------------------------------------------------
/app/src/main/res/drawable-xxhdpi/ic_add.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ossw/ossw-android/HEAD/app/src/main/res/drawable-xxhdpi/ic_add.png
--------------------------------------------------------------------------------
/app/src/main/res/drawable-xxhdpi/ic_exit.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ossw/ossw-android/HEAD/app/src/main/res/drawable-xxhdpi/ic_exit.png
--------------------------------------------------------------------------------
/app/src/main/res/drawable-xxhdpi/ic_play.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ossw/ossw-android/HEAD/app/src/main/res/drawable-xxhdpi/ic_play.png
--------------------------------------------------------------------------------
/app/src/main/res/drawable-xxhdpi/ic_stop.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ossw/ossw-android/HEAD/app/src/main/res/drawable-xxhdpi/ic_stop.png
--------------------------------------------------------------------------------
/app/src/main/res/drawable-xxhdpi/ic_tools.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ossw/ossw-android/HEAD/app/src/main/res/drawable-xxhdpi/ic_tools.png
--------------------------------------------------------------------------------
/app/src/main/res/drawable-xxhdpi/ic_watch.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ossw/ossw-android/HEAD/app/src/main/res/drawable-xxhdpi/ic_watch.png
--------------------------------------------------------------------------------
/app/src/main/res/drawable/button_select.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ossw/ossw-android/HEAD/app/src/main/res/drawable/button_select.png
--------------------------------------------------------------------------------
/app/src/main/res/drawable-hdpi/ic_download.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ossw/ossw-android/HEAD/app/src/main/res/drawable-hdpi/ic_download.png
--------------------------------------------------------------------------------
/app/src/main/res/drawable-hdpi/ic_extension.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ossw/ossw-android/HEAD/app/src/main/res/drawable-hdpi/ic_extension.png
--------------------------------------------------------------------------------
/app/src/main/res/drawable-hdpi/ic_launcher.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ossw/ossw-android/HEAD/app/src/main/res/drawable-hdpi/ic_launcher.png
--------------------------------------------------------------------------------
/app/src/main/res/drawable-hdpi/ic_settings.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ossw/ossw-android/HEAD/app/src/main/res/drawable-hdpi/ic_settings.png
--------------------------------------------------------------------------------
/app/src/main/res/drawable-hdpi/ic_watch_off.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ossw/ossw-android/HEAD/app/src/main/res/drawable-hdpi/ic_watch_off.png
--------------------------------------------------------------------------------
/app/src/main/res/drawable-hdpi/ic_watchface.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ossw/ossw-android/HEAD/app/src/main/res/drawable-hdpi/ic_watchface.png
--------------------------------------------------------------------------------
/app/src/main/res/drawable-mdpi/ic_download.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ossw/ossw-android/HEAD/app/src/main/res/drawable-mdpi/ic_download.png
--------------------------------------------------------------------------------
/app/src/main/res/drawable-mdpi/ic_extension.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ossw/ossw-android/HEAD/app/src/main/res/drawable-mdpi/ic_extension.png
--------------------------------------------------------------------------------
/app/src/main/res/drawable-mdpi/ic_launcher.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ossw/ossw-android/HEAD/app/src/main/res/drawable-mdpi/ic_launcher.png
--------------------------------------------------------------------------------
/app/src/main/res/drawable-mdpi/ic_settings.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ossw/ossw-android/HEAD/app/src/main/res/drawable-mdpi/ic_settings.png
--------------------------------------------------------------------------------
/app/src/main/res/drawable-mdpi/ic_watch_off.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ossw/ossw-android/HEAD/app/src/main/res/drawable-mdpi/ic_watch_off.png
--------------------------------------------------------------------------------
/app/src/main/res/drawable-mdpi/ic_watchface.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ossw/ossw-android/HEAD/app/src/main/res/drawable-mdpi/ic_watchface.png
--------------------------------------------------------------------------------
/app/src/main/res/drawable-xhdpi/ic_download.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ossw/ossw-android/HEAD/app/src/main/res/drawable-xhdpi/ic_download.png
--------------------------------------------------------------------------------
/app/src/main/res/drawable-xhdpi/ic_forward.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ossw/ossw-android/HEAD/app/src/main/res/drawable-xhdpi/ic_forward.png
--------------------------------------------------------------------------------
/app/src/main/res/drawable-xhdpi/ic_launcher.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ossw/ossw-android/HEAD/app/src/main/res/drawable-xhdpi/ic_launcher.png
--------------------------------------------------------------------------------
/app/src/main/res/drawable-xhdpi/ic_preview.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ossw/ossw-android/HEAD/app/src/main/res/drawable-xhdpi/ic_preview.png
--------------------------------------------------------------------------------
/app/src/main/res/drawable-xhdpi/ic_refresh.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ossw/ossw-android/HEAD/app/src/main/res/drawable-xhdpi/ic_refresh.png
--------------------------------------------------------------------------------
/app/src/main/res/drawable-xhdpi/ic_settings.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ossw/ossw-android/HEAD/app/src/main/res/drawable-xhdpi/ic_settings.png
--------------------------------------------------------------------------------
/app/src/main/res/drawable-xxhdpi/ic_delete.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ossw/ossw-android/HEAD/app/src/main/res/drawable-xxhdpi/ic_delete.png
--------------------------------------------------------------------------------
/app/src/main/res/drawable-xxhdpi/ic_forward.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ossw/ossw-android/HEAD/app/src/main/res/drawable-xxhdpi/ic_forward.png
--------------------------------------------------------------------------------
/app/src/main/res/drawable-xxhdpi/ic_preview.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ossw/ossw-android/HEAD/app/src/main/res/drawable-xxhdpi/ic_preview.png
--------------------------------------------------------------------------------
/app/src/main/res/drawable-xxhdpi/ic_refresh.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ossw/ossw-android/HEAD/app/src/main/res/drawable-xxhdpi/ic_refresh.png
--------------------------------------------------------------------------------
/app/src/main/res/drawable-xxhdpi/ic_upload.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ossw/ossw-android/HEAD/app/src/main/res/drawable-xxhdpi/ic_upload.png
--------------------------------------------------------------------------------
/app/src/main/res/drawable-hdpi-v9/ic_watch_off.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ossw/ossw-android/HEAD/app/src/main/res/drawable-hdpi-v9/ic_watch_off.png
--------------------------------------------------------------------------------
/app/src/main/res/drawable-hdpi/ic_categorize.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ossw/ossw-android/HEAD/app/src/main/res/drawable-hdpi/ic_categorize.png
--------------------------------------------------------------------------------
/app/src/main/res/drawable-hdpi/ic_watch_dial.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ossw/ossw-android/HEAD/app/src/main/res/drawable-hdpi/ic_watch_dial.png
--------------------------------------------------------------------------------
/app/src/main/res/drawable-mdpi-v9/ic_watch_off.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ossw/ossw-android/HEAD/app/src/main/res/drawable-mdpi-v9/ic_watch_off.png
--------------------------------------------------------------------------------
/app/src/main/res/drawable-mdpi/ic_categorize.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ossw/ossw-android/HEAD/app/src/main/res/drawable-mdpi/ic_categorize.png
--------------------------------------------------------------------------------
/app/src/main/res/drawable-mdpi/ic_watch_dial.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ossw/ossw-android/HEAD/app/src/main/res/drawable-mdpi/ic_watch_dial.png
--------------------------------------------------------------------------------
/app/src/main/res/drawable-xhdpi/ic_categorize.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ossw/ossw-android/HEAD/app/src/main/res/drawable-xhdpi/ic_categorize.png
--------------------------------------------------------------------------------
/app/src/main/res/drawable-xhdpi/ic_extension.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ossw/ossw-android/HEAD/app/src/main/res/drawable-xhdpi/ic_extension.png
--------------------------------------------------------------------------------
/app/src/main/res/drawable-xhdpi/ic_watch_dial.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ossw/ossw-android/HEAD/app/src/main/res/drawable-xhdpi/ic_watch_dial.png
--------------------------------------------------------------------------------
/app/src/main/res/drawable-xhdpi/ic_watch_off.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ossw/ossw-android/HEAD/app/src/main/res/drawable-xhdpi/ic_watch_off.png
--------------------------------------------------------------------------------
/app/src/main/res/drawable-xhdpi/ic_watchface.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ossw/ossw-android/HEAD/app/src/main/res/drawable-xhdpi/ic_watchface.png
--------------------------------------------------------------------------------
/app/src/main/res/drawable-xxhdpi/ic_categorize.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ossw/ossw-android/HEAD/app/src/main/res/drawable-xxhdpi/ic_categorize.png
--------------------------------------------------------------------------------
/app/src/main/res/drawable-xxhdpi/ic_download.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ossw/ossw-android/HEAD/app/src/main/res/drawable-xxhdpi/ic_download.png
--------------------------------------------------------------------------------
/app/src/main/res/drawable-xxhdpi/ic_extension.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ossw/ossw-android/HEAD/app/src/main/res/drawable-xxhdpi/ic_extension.png
--------------------------------------------------------------------------------
/app/src/main/res/drawable-xxhdpi/ic_launcher.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ossw/ossw-android/HEAD/app/src/main/res/drawable-xxhdpi/ic_launcher.png
--------------------------------------------------------------------------------
/app/src/main/res/drawable-xxhdpi/ic_settings.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ossw/ossw-android/HEAD/app/src/main/res/drawable-xxhdpi/ic_settings.png
--------------------------------------------------------------------------------
/app/src/main/res/drawable-xxhdpi/ic_watch_dial.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ossw/ossw-android/HEAD/app/src/main/res/drawable-xxhdpi/ic_watch_dial.png
--------------------------------------------------------------------------------
/app/src/main/res/drawable-xxhdpi/ic_watch_off.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ossw/ossw-android/HEAD/app/src/main/res/drawable-xxhdpi/ic_watch_off.png
--------------------------------------------------------------------------------
/app/src/main/res/drawable-xxhdpi/ic_watchface.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ossw/ossw-android/HEAD/app/src/main/res/drawable-xxhdpi/ic_watchface.png
--------------------------------------------------------------------------------
/app/src/main/res/drawable-xxxhdpi/ic_launcher.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ossw/ossw-android/HEAD/app/src/main/res/drawable-xxxhdpi/ic_launcher.png
--------------------------------------------------------------------------------
/app/src/main/res/drawable-hdpi-v11/ic_watch_dial.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ossw/ossw-android/HEAD/app/src/main/res/drawable-hdpi-v11/ic_watch_dial.png
--------------------------------------------------------------------------------
/app/src/main/res/drawable-hdpi-v11/ic_watch_off.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ossw/ossw-android/HEAD/app/src/main/res/drawable-hdpi-v11/ic_watch_off.png
--------------------------------------------------------------------------------
/app/src/main/res/drawable-hdpi-v9/ic_watch_dial.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ossw/ossw-android/HEAD/app/src/main/res/drawable-hdpi-v9/ic_watch_dial.png
--------------------------------------------------------------------------------
/app/src/main/res/drawable-mdpi-v11/ic_watch_dial.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ossw/ossw-android/HEAD/app/src/main/res/drawable-mdpi-v11/ic_watch_dial.png
--------------------------------------------------------------------------------
/app/src/main/res/drawable-mdpi-v11/ic_watch_off.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ossw/ossw-android/HEAD/app/src/main/res/drawable-mdpi-v11/ic_watch_off.png
--------------------------------------------------------------------------------
/app/src/main/res/drawable-mdpi-v9/ic_watch_dial.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ossw/ossw-android/HEAD/app/src/main/res/drawable-mdpi-v9/ic_watch_dial.png
--------------------------------------------------------------------------------
/app/src/main/res/drawable-xhdpi-v11/ic_watch_off.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ossw/ossw-android/HEAD/app/src/main/res/drawable-xhdpi-v11/ic_watch_off.png
--------------------------------------------------------------------------------
/app/src/main/res/drawable-xhdpi-v9/ic_watch_dial.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ossw/ossw-android/HEAD/app/src/main/res/drawable-xhdpi-v9/ic_watch_dial.png
--------------------------------------------------------------------------------
/app/src/main/res/drawable-xhdpi-v9/ic_watch_off.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ossw/ossw-android/HEAD/app/src/main/res/drawable-xhdpi-v9/ic_watch_off.png
--------------------------------------------------------------------------------
/app/src/main/res/drawable-xxhdpi-v9/ic_watch_off.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ossw/ossw-android/HEAD/app/src/main/res/drawable-xxhdpi-v9/ic_watch_off.png
--------------------------------------------------------------------------------
/app/src/main/res/drawable-xhdpi-v11/ic_watch_dial.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ossw/ossw-android/HEAD/app/src/main/res/drawable-xhdpi-v11/ic_watch_dial.png
--------------------------------------------------------------------------------
/app/src/main/res/drawable-xxhdpi-v11/ic_watch_dial.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ossw/ossw-android/HEAD/app/src/main/res/drawable-xxhdpi-v11/ic_watch_dial.png
--------------------------------------------------------------------------------
/app/src/main/res/drawable-xxhdpi-v11/ic_watch_off.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ossw/ossw-android/HEAD/app/src/main/res/drawable-xxhdpi-v11/ic_watch_off.png
--------------------------------------------------------------------------------
/app/src/main/res/drawable-xxhdpi-v9/ic_watch_dial.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ossw/ossw-android/HEAD/app/src/main/res/drawable-xxhdpi-v9/ic_watch_dial.png
--------------------------------------------------------------------------------
/app/src/main/res/drawable-hdpi/ic_crop_free_black_48dp.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ossw/ossw-android/HEAD/app/src/main/res/drawable-hdpi/ic_crop_free_black_48dp.png
--------------------------------------------------------------------------------
/app/src/main/res/drawable-hdpi/ic_file_upload_black_18dp.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ossw/ossw-android/HEAD/app/src/main/res/drawable-hdpi/ic_file_upload_black_18dp.png
--------------------------------------------------------------------------------
/app/src/main/res/drawable-mdpi/ic_crop_free_black_48dp.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ossw/ossw-android/HEAD/app/src/main/res/drawable-mdpi/ic_crop_free_black_48dp.png
--------------------------------------------------------------------------------
/app/src/main/res/drawable-mdpi/ic_file_upload_black_18dp.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ossw/ossw-android/HEAD/app/src/main/res/drawable-mdpi/ic_file_upload_black_18dp.png
--------------------------------------------------------------------------------
/app/src/main/res/drawable-xhdpi/ic_crop_free_black_48dp.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ossw/ossw-android/HEAD/app/src/main/res/drawable-xhdpi/ic_crop_free_black_48dp.png
--------------------------------------------------------------------------------
/app/src/main/res/drawable-xxhdpi/ic_crop_free_black_48dp.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ossw/ossw-android/HEAD/app/src/main/res/drawable-xxhdpi/ic_crop_free_black_48dp.png
--------------------------------------------------------------------------------
/app/src/main/res/drawable-xhdpi/ic_file_upload_black_18dp.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ossw/ossw-android/HEAD/app/src/main/res/drawable-xhdpi/ic_file_upload_black_18dp.png
--------------------------------------------------------------------------------
/app/src/main/res/drawable-xxhdpi/ic_file_upload_black_18dp.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ossw/ossw-android/HEAD/app/src/main/res/drawable-xxhdpi/ic_file_upload_black_18dp.png
--------------------------------------------------------------------------------
/app/src/main/res/drawable-xxxhdpi/ic_crop_free_black_48dp.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ossw/ossw-android/HEAD/app/src/main/res/drawable-xxxhdpi/ic_crop_free_black_48dp.png
--------------------------------------------------------------------------------
/app/src/main/res/drawable-xxxhdpi/ic_file_upload_black_18dp.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ossw/ossw-android/HEAD/app/src/main/res/drawable-xxxhdpi/ic_file_upload_black_18dp.png
--------------------------------------------------------------------------------
/.idea/encodings.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
--------------------------------------------------------------------------------
/.idea/vcs.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
--------------------------------------------------------------------------------
/app/src/main/java/com/althink/android/ossw/emulator/event/EmulatorEvent.java:
--------------------------------------------------------------------------------
1 | package com.althink.android.ossw.emulator.event;
2 |
3 | /**
4 | * Created by krzysiek on 14/06/15.
5 | */
6 | public interface EmulatorEvent {
7 | }
8 |
--------------------------------------------------------------------------------
/app/src/main/java/com/althink/android/ossw/UploadDataType.java:
--------------------------------------------------------------------------------
1 | package com.althink.android.ossw;
2 |
3 | /**
4 | * Created by krzysiek on 20/06/15.
5 | */
6 | public enum UploadDataType {
7 | WATCH_FACE, APPLICATION, UTILITY
8 | }
9 |
--------------------------------------------------------------------------------
/.gitignore:
--------------------------------------------------------------------------------
1 | I.gradle
2 | /local.properties
3 | /.idea/workspace.xml
4 | /.idea/libraries
5 | /.idea/datasources.xml
6 | /.idea/dataSources.ids
7 | .DS_Store
8 | /build
9 | *.apk
10 | *.ap_
11 | *.dex
12 | bin/
13 | gen/
14 | .gradle
15 |
--------------------------------------------------------------------------------
/app/src/main/java/com/althink/android/ossw/watchsets/WatchSetType.java:
--------------------------------------------------------------------------------
1 | package com.althink.android.ossw.watchsets;
2 |
3 | /**
4 | * Created by krzysiek on 08/11/15.
5 | */
6 | public enum WatchSetType {
7 | WATCH_FACE, APPLICATION, UTILITY
8 | }
9 |
--------------------------------------------------------------------------------
/app/src/main/java/com/althink/android/ossw/emulator/event/EmulatorButton.java:
--------------------------------------------------------------------------------
1 | package com.althink.android.ossw.emulator.event;
2 |
3 | /**
4 | * Created by krzysiek on 14/06/15.
5 | */
6 | public enum EmulatorButton {
7 | UP, DOWN, SELECT, BACK
8 | }
9 |
--------------------------------------------------------------------------------
/app/src/main/java/com/althink/android/ossw/emulator/fonts/EmulatorFont.java:
--------------------------------------------------------------------------------
1 | package com.althink.android.ossw.emulator.fonts;
2 |
3 | /**
4 | * Created by krzysiek on 05/07/15.
5 | */
6 | public interface EmulatorFont {
7 | FontInfo getFontInfo();
8 | }
9 |
--------------------------------------------------------------------------------
/app/src/main/java/com/althink/android/ossw/plugins/PluginPropertyType.java:
--------------------------------------------------------------------------------
1 | package com.althink.android.ossw.plugins;
2 |
3 | /**
4 | * Created by krzysiek on 24/06/15.
5 | */
6 | public enum PluginPropertyType {
7 | INTEGER, FLOAT, STRING, ENUM;
8 | }
9 |
--------------------------------------------------------------------------------
/app/src/main/java/com/althink/android/ossw/watchsets/ValueResolver.java:
--------------------------------------------------------------------------------
1 | package com.althink.android.ossw.watchsets;
2 |
3 | /**
4 | * Created by krzysiek on 21/11/15.
5 | */
6 | public interface ValueResolver {
7 | Object resolve(Object value);
8 | }
9 |
--------------------------------------------------------------------------------
/app/src/main/res/values-hdpi/dimens.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 | 288px
4 | 336px
5 | 100px
6 |
7 |
--------------------------------------------------------------------------------
/app/src/main/res/values-mdpi/dimens.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 | 288px
4 | 336px
5 | 100px
6 |
7 |
--------------------------------------------------------------------------------
/app/src/main/res/values-xhdpi/dimens.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 | 432px
4 | 504px
5 | 150px
6 |
7 |
--------------------------------------------------------------------------------
/app/src/main/res/values-xxhdpi/dimens.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 | 576px
4 | 672px
5 | 200px
6 |
7 |
--------------------------------------------------------------------------------
/app/src/main/java/com/althink/android/ossw/emulator/source/EmulatorResourceSource.java:
--------------------------------------------------------------------------------
1 | package com.althink.android.ossw.emulator.source;
2 |
3 | /**
4 | * Created by krzysiek on 08/09/15.
5 | */
6 | public interface EmulatorResourceSource {
7 | byte[] getData();
8 | }
9 |
--------------------------------------------------------------------------------
/app/src/main/java/com/althink/android/ossw/notifications/NotificationHandler.java:
--------------------------------------------------------------------------------
1 | package com.althink.android.ossw.notifications;
2 |
3 | /**
4 | * Created by krzysiek on 19/07/15.
5 | */
6 | public interface NotificationHandler {
7 | void handleFunction(int functionId);
8 | }
9 |
--------------------------------------------------------------------------------
/app/src/main/java/com/althink/android/ossw/service/ble/ReadCharacteristicHandler.java:
--------------------------------------------------------------------------------
1 | package com.althink.android.ossw.service.ble;
2 |
3 | /**
4 | * Created by krzysiek on 10/10/15.
5 | */
6 | public interface ReadCharacteristicHandler {
7 | void handleValue(byte[] data);
8 | }
9 |
--------------------------------------------------------------------------------
/gradle/wrapper/gradle-wrapper.properties:
--------------------------------------------------------------------------------
1 | #Wed Apr 10 15:27:10 PDT 2013
2 | distributionBase=GRADLE_USER_HOME
3 | distributionPath=wrapper/dists
4 | zipStoreBase=GRADLE_USER_HOME
5 | zipStorePath=wrapper/dists
6 | distributionUrl=https\://services.gradle.org/distributions/gradle-2.9-all.zip
7 |
--------------------------------------------------------------------------------
/app/src/main/java/com/althink/android/ossw/emulator/source/converter/EmulatorDataConverter.java:
--------------------------------------------------------------------------------
1 | package com.althink.android.ossw.emulator.source.converter;
2 |
3 | /**
4 | * Created by krzysiek on 29/11/15.
5 | */
6 | public interface EmulatorDataConverter {
7 | Object convert(Object value);
8 | }
9 |
--------------------------------------------------------------------------------
/app/src/main/java/com/althink/android/ossw/notifications/message/NotificationMessageBuilder.java:
--------------------------------------------------------------------------------
1 | package com.althink.android.ossw.notifications.message;
2 |
3 | /**
4 | * Created by krzysiek on 19/07/15.
5 | */
6 | public interface NotificationMessageBuilder {
7 |
8 | byte[] build();
9 | }
10 |
--------------------------------------------------------------------------------
/app/src/main/java/com/althink/android/ossw/notifications/parser/api18/MessageParser.java:
--------------------------------------------------------------------------------
1 | //package com.althink.android.ossw.notifications.model.api19;
2 | //
3 | //import android.app.Notification;
4 | //
5 | //public interface MessageParser {
6 | // public Message parse(Notification notification);
7 | //}
8 |
--------------------------------------------------------------------------------
/app/src/main/res/layout/toolbar_default.xml:
--------------------------------------------------------------------------------
1 |
4 |
--------------------------------------------------------------------------------
/app/src/main/res/layout/pref_switch.xml:
--------------------------------------------------------------------------------
1 |
2 |
6 |
--------------------------------------------------------------------------------
/app/src/main/java/com/althink/android/ossw/service/ble/BleConnectionStatusHandler.java:
--------------------------------------------------------------------------------
1 | package com.althink.android.ossw.service.ble;
2 |
3 | /**
4 | * Created by krzysiek on 10/10/15.
5 | */
6 | public interface BleConnectionStatusHandler {
7 | void handleConnectionStatusChange(BleConnectionStatus status);
8 | }
9 |
--------------------------------------------------------------------------------
/app/src/main/java/com/althink/android/ossw/notifications/parser/api18/NotificationType.java:
--------------------------------------------------------------------------------
1 | //package com.althink.android.ossw.notifications.model.api19;
2 | //
3 | ///**
4 | // * Created by krzysiek on 22/07/15.
5 | // */
6 | //public enum NotificationType {
7 | // SMS, EMAIL, INSTANT_MESSAGE, MISSED_CALL, OTHER
8 | //}
9 |
--------------------------------------------------------------------------------
/app/src/main/java/com/althink/android/ossw/notifications/parser/api18/MessageInfo.java:
--------------------------------------------------------------------------------
1 | //package com.althink.android.ossw.notifications.model.api19;
2 | //
3 | ///**
4 | // * Created by krzysiek on 22/07/15.
5 | // */
6 | //public class MessageInfo {
7 | //
8 | // public String subject;
9 | // public String info;
10 | //}
11 |
--------------------------------------------------------------------------------
/app/src/main/java/com/althink/android/ossw/watchsets/UtilitiesFragment.java:
--------------------------------------------------------------------------------
1 | package com.althink.android.ossw.watchsets;
2 |
3 | /**
4 | * Created by krzysiek on 08/11/15.
5 | */
6 | public class UtilitiesFragment extends WatchSetsFragment {
7 |
8 | public UtilitiesFragment() {
9 | super(WatchSetType.UTILITY);
10 | }
11 | }
12 |
--------------------------------------------------------------------------------
/app/src/main/java/com/althink/android/ossw/watchsets/WatchFacesFragment.java:
--------------------------------------------------------------------------------
1 | package com.althink.android.ossw.watchsets;
2 |
3 | /**
4 | * Created by krzysiek on 08/11/15.
5 | */
6 | public class WatchFacesFragment extends WatchSetsFragment {
7 |
8 | public WatchFacesFragment () {
9 | super(WatchSetType.WATCH_FACE);
10 | }
11 | }
12 |
--------------------------------------------------------------------------------
/app/src/main/res/layout/pref_image_play.xml:
--------------------------------------------------------------------------------
1 |
2 |
8 |
--------------------------------------------------------------------------------
/app/src/main/java/com/althink/android/ossw/watchsets/ApplicationsFragment.java:
--------------------------------------------------------------------------------
1 | package com.althink.android.ossw.watchsets;
2 |
3 | /**
4 | * Created by krzysiek on 08/11/15.
5 | */
6 | public class ApplicationsFragment extends WatchSetsFragment {
7 |
8 | public ApplicationsFragment() {
9 | super(WatchSetType.APPLICATION);
10 | }
11 | }
12 |
--------------------------------------------------------------------------------
/app/src/main/java/com/althink/android/ossw/emulator/source/converter/MockConverter.java:
--------------------------------------------------------------------------------
1 | package com.althink.android.ossw.emulator.source.converter;
2 |
3 | /**
4 | * Created by krzysiek on 29/11/15.
5 | */
6 | public class MockConverter implements EmulatorDataConverter {
7 | @Override
8 | public Object convert(Object value) {
9 | return value;
10 | }
11 | }
12 |
--------------------------------------------------------------------------------
/app/src/main/java/com/althink/android/ossw/emulator/actions/EmulatorAction.java:
--------------------------------------------------------------------------------
1 | package com.althink.android.ossw.emulator.actions;
2 |
3 | import com.althink.android.ossw.emulator.renderer.EmulatorExecutionContext;
4 |
5 | /**
6 | * Created by krzysiek on 18/06/15.
7 | */
8 | public interface EmulatorAction {
9 |
10 | void performAction(EmulatorExecutionContext ctx);
11 | }
12 |
--------------------------------------------------------------------------------
/app/src/main/java/com/althink/android/ossw/emulator/event/ButtonPressedEmulatorEvent.java:
--------------------------------------------------------------------------------
1 | package com.althink.android.ossw.emulator.event;
2 |
3 | /**
4 | * Created by krzysiek on 14/06/15.
5 | */
6 | public class ButtonPressedEmulatorEvent extends AbstractButtonEmulatorEvent {
7 | public ButtonPressedEmulatorEvent(EmulatorButton button) {
8 | super(button);
9 | }
10 | }
11 |
--------------------------------------------------------------------------------
/.idea/modules.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
8 |
9 |
--------------------------------------------------------------------------------
/app/src/main/java/com/althink/android/ossw/emulator/event/ButtonLongPressedEmulatorEvent.java:
--------------------------------------------------------------------------------
1 | package com.althink.android.ossw.emulator.event;
2 |
3 | /**
4 | * Created by krzysiek on 14/06/15.
5 | */
6 | public class ButtonLongPressedEmulatorEvent extends AbstractButtonEmulatorEvent {
7 | public ButtonLongPressedEmulatorEvent(EmulatorButton button) {
8 | super(button);
9 | }
10 | }
11 |
--------------------------------------------------------------------------------
/app/src/main/java/com/althink/android/ossw/emulator/renderer/ScreenRender.java:
--------------------------------------------------------------------------------
1 | package com.althink.android.ossw.emulator.renderer;
2 |
3 | import com.althink.android.ossw.emulator.event.EmulatorEvent;
4 |
5 | /**
6 | * Created by krzysiek on 14/06/15.
7 | */
8 | public interface ScreenRender {
9 | void render(LowLevelRenderer renderer);
10 |
11 | void handleEvent(EmulatorEvent event);
12 | }
13 |
--------------------------------------------------------------------------------
/app/src/main/res/values-w820dp/dimens.xml:
--------------------------------------------------------------------------------
1 |
2 |
5 | 64dp
6 |
7 |
--------------------------------------------------------------------------------
/app/src/main/res/drawable/row_selector.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
--------------------------------------------------------------------------------
/app/src/main/java/com/althink/android/ossw/watchsets/DataSourceType.java:
--------------------------------------------------------------------------------
1 | package com.althink.android.ossw.watchsets;
2 |
3 | /**
4 | * Created by krzysiek on 22/06/15.
5 | */
6 | public enum DataSourceType {
7 | NUMBER(1), STRING(2);
8 |
9 | private int key;
10 |
11 | private DataSourceType(int key) {
12 | this.key = key;
13 | }
14 |
15 | public int getKey() {
16 | return key;
17 | }
18 | }
19 |
--------------------------------------------------------------------------------
/app/src/main/java/com/althink/android/ossw/notifications/parser/NotificationIdBuilder.java:
--------------------------------------------------------------------------------
1 | package com.althink.android.ossw.notifications.parser;
2 |
3 | import android.service.notification.StatusBarNotification;
4 |
5 | /**
6 | * Created by krzysiek on 25/07/15.
7 | */
8 | public class NotificationIdBuilder {
9 | public String build(StatusBarNotification sbn) {
10 | return sbn.getPackageName() + ":" + sbn.getId();
11 | }
12 | }
13 |
--------------------------------------------------------------------------------
/app/src/main/java/com/althink/android/ossw/watchsets/KnownParseError.java:
--------------------------------------------------------------------------------
1 | package com.althink.android.ossw.watchsets;
2 |
3 | /**
4 | * Created by krzysiek on 29/06/15.
5 | */
6 | public class KnownParseError extends RuntimeException {
7 |
8 | public KnownParseError(String message) {
9 | super(message);
10 | }
11 |
12 | public KnownParseError(String message, Exception e) {
13 | super(message, e);
14 | }
15 | }
16 |
--------------------------------------------------------------------------------
/app/src/main/java/com/althink/android/ossw/service/ble/CharacteristicChangeHandler.java:
--------------------------------------------------------------------------------
1 | package com.althink.android.ossw.service.ble;
2 |
3 | import android.bluetooth.BluetoothGatt;
4 | import android.bluetooth.BluetoothGattCharacteristic;
5 |
6 | /**
7 | * Created by krzysiek on 10/10/15.
8 | */
9 | public interface CharacteristicChangeHandler {
10 | void handleCharacteristicChange(BluetoothGatt gatt, BluetoothGattCharacteristic characteristic);
11 | }
12 |
--------------------------------------------------------------------------------
/app/src/main/res/anim/slide_in.xml:
--------------------------------------------------------------------------------
1 |
2 |
4 |
10 |
--------------------------------------------------------------------------------
/app/src/main/res/anim/slide_out.xml:
--------------------------------------------------------------------------------
1 |
2 |
4 |
10 |
--------------------------------------------------------------------------------
/app/src/androidTest/java/com/althink/android/ossw/ApplicationTest.java:
--------------------------------------------------------------------------------
1 | package com.althink.android.ossw;
2 |
3 | import android.app.Application;
4 | import android.test.ApplicationTestCase;
5 |
6 | /**
7 | * Testing Fundamentals
8 | */
9 | public class ApplicationTest extends ApplicationTestCase {
10 | public ApplicationTest() {
11 | super(Application.class);
12 | }
13 | }
--------------------------------------------------------------------------------
/app/src/main/java/com/althink/android/ossw/emulator/control/EmulatorControl.java:
--------------------------------------------------------------------------------
1 | package com.althink.android.ossw.emulator.control;
2 |
3 | import com.althink.android.ossw.emulator.renderer.EmulatorExecutionContext;
4 | import com.althink.android.ossw.emulator.renderer.LowLevelRenderer;
5 |
6 | /**
7 | * Created by krzysiek on 14/06/15.
8 | */
9 | public interface EmulatorControl {
10 |
11 | void draw(LowLevelRenderer renderer, EmulatorExecutionContext ctx);
12 | }
13 |
--------------------------------------------------------------------------------
/app/src/main/java/com/althink/android/ossw/notifications/model/NotificationType.java:
--------------------------------------------------------------------------------
1 | package com.althink.android.ossw.notifications.model;
2 |
3 | /**
4 | * Created by krzysiek on 24/07/15.
5 | */
6 | public enum NotificationType {
7 | ALERT(1), INFO(2), UPDATE(3);
8 |
9 | private int value;
10 |
11 | NotificationType(int value) {
12 | this.value = value;
13 | }
14 |
15 | public int getValue() {
16 | return value;
17 | }
18 | }
19 |
--------------------------------------------------------------------------------
/app/src/main/java/com/althink/android/ossw/emulator/source/EmulatorDataSource.java:
--------------------------------------------------------------------------------
1 | package com.althink.android.ossw.emulator.source;
2 |
3 | import com.althink.android.ossw.emulator.renderer.EmulatorExecutionContext;
4 | import com.althink.android.ossw.watchsets.DataSourceType;
5 |
6 | /**
7 | * Created by krzysiek on 14/06/15.
8 | */
9 | public interface EmulatorDataSource {
10 |
11 | public Object getData(DataSourceType type, int range, EmulatorExecutionContext ctx);
12 | }
13 |
--------------------------------------------------------------------------------
/app/src/main/java/com/althink/android/ossw/utils/StringNormalizer.java:
--------------------------------------------------------------------------------
1 | package com.althink.android.ossw.utils;
2 |
3 | import net.sf.junidecode.Junidecode;
4 |
5 | /**
6 | * Created by krzysiek on 19/07/15.
7 | */
8 | public class StringNormalizer {
9 |
10 | public static String removeAccents(String text) {
11 | if (text == null) {
12 | return null;
13 | }
14 | String result = Junidecode.unidecode(text);
15 | return result;
16 | }
17 | }
18 |
--------------------------------------------------------------------------------
/app/src/main/java/com/althink/android/ossw/emulator/source/converter/OnesConverter.java:
--------------------------------------------------------------------------------
1 | package com.althink.android.ossw.emulator.source.converter;
2 |
3 | /**
4 | * Created by krzysiek on 01/12/15.
5 | */
6 | public class OnesConverter implements EmulatorDataConverter {
7 | @Override
8 | public Object convert(Object value) {
9 | if (!(value instanceof Integer)) {
10 | return 0;
11 | }
12 | int v = (Integer) value;
13 | return v%10;
14 | }
15 | }
16 |
--------------------------------------------------------------------------------
/app/src/main/java/com/althink/android/ossw/emulator/source/converter/TensConverter.java:
--------------------------------------------------------------------------------
1 | package com.althink.android.ossw.emulator.source.converter;
2 |
3 | /**
4 | * Created by krzysiek on 01/12/15.
5 | */
6 | public class TensConverter implements EmulatorDataConverter {
7 | @Override
8 | public Object convert(Object value) {
9 | if (!(value instanceof Integer)) {
10 | return 0;
11 | }
12 | int v = (Integer) value;
13 | return (v/10)%10;
14 | }
15 | }
16 |
--------------------------------------------------------------------------------
/app/src/main/java/com/althink/android/ossw/emulator/source/converter/HundredsConverter.java:
--------------------------------------------------------------------------------
1 | package com.althink.android.ossw.emulator.source.converter;
2 |
3 | /**
4 | * Created by krzysiek on 01/12/15.
5 | */
6 | public class HundredsConverter implements EmulatorDataConverter {
7 | @Override
8 | public Object convert(Object value) {
9 | if (!(value instanceof Integer)) {
10 | return 0;
11 | }
12 | int v = (Integer) value;
13 | return (v/100)%10;
14 | }
15 | }
16 |
--------------------------------------------------------------------------------
/app/src/main/java/com/althink/android/ossw/notifications/model/NotificationCategory.java:
--------------------------------------------------------------------------------
1 | package com.althink.android.ossw.notifications.model;
2 |
3 | /**
4 | * Created by krzysiek on 24/07/15.
5 | */
6 | public enum NotificationCategory {
7 | INCOMING_CALL(1), MESSAGE(2), EMAIL(3), SOCIAL(4), ALARM(5), OTHER(255);
8 |
9 | private int value;
10 |
11 | NotificationCategory(int value) {
12 | this.value = value;
13 | }
14 |
15 | public int getValue() {
16 | return value;
17 | }
18 | }
19 |
--------------------------------------------------------------------------------
/app/src/main/java/com/althink/android/ossw/emulator/control/digits/DigitsRenderer.java:
--------------------------------------------------------------------------------
1 | package com.althink.android.ossw.emulator.control.digits;
2 |
3 | import com.althink.android.ossw.emulator.renderer.LowLevelRenderer;
4 |
5 | /**
6 | * Created by krzysiek on 11/09/15.
7 | */
8 | public interface DigitsRenderer {
9 |
10 | int renderDigit(LowLevelRenderer renderer, int digit, int x, int y, boolean fullWidth, boolean drawZero);
11 |
12 | int renderDecimalSeparator(LowLevelRenderer renderer, int x, int y);
13 |
14 | }
15 |
--------------------------------------------------------------------------------
/app/src/main/java/com/althink/android/ossw/emulator/source/converter/TimeToHour24Converter.java:
--------------------------------------------------------------------------------
1 | package com.althink.android.ossw.emulator.source.converter;
2 |
3 | /**
4 | * Created by krzysiek on 29/11/15.
5 | */
6 | public class TimeToHour24Converter implements EmulatorDataConverter {
7 |
8 | @Override
9 | public Object convert(Object value) {
10 | if (!(value instanceof Integer)) {
11 | return 0;
12 | }
13 | int v = (Integer) value;
14 | return v / 3600;
15 | }
16 | }
17 |
--------------------------------------------------------------------------------
/app/src/main/java/com/althink/android/ossw/emulator/source/converter/TimeToSecondsConverter.java:
--------------------------------------------------------------------------------
1 | package com.althink.android.ossw.emulator.source.converter;
2 |
3 | /**
4 | * Created by krzysiek on 29/11/15.
5 | */
6 | public class TimeToSecondsConverter implements EmulatorDataConverter {
7 |
8 | @Override
9 | public Object convert(Object value) {
10 | if (!(value instanceof Integer)) {
11 | return 0;
12 | }
13 | int v = (Integer) value;
14 | return v % 60;
15 | }
16 | }
17 |
--------------------------------------------------------------------------------
/app/src/main/java/com/althink/android/ossw/emulator/source/converter/TimeToMinutesConverter.java:
--------------------------------------------------------------------------------
1 | package com.althink.android.ossw.emulator.source.converter;
2 |
3 | /**
4 | * Created by krzysiek on 29/11/15.
5 | */
6 | public class TimeToMinutesConverter implements EmulatorDataConverter {
7 |
8 | @Override
9 | public Object convert(Object value) {
10 | if (!(value instanceof Integer)) {
11 | return 0;
12 | }
13 | int v = (Integer) value;
14 | return (v % 3600) / 60;
15 | }
16 | }
17 |
--------------------------------------------------------------------------------
/app/src/main/java/com/althink/android/ossw/emulator/source/converter/Hour24ToHour12Converter.java:
--------------------------------------------------------------------------------
1 | package com.althink.android.ossw.emulator.source.converter;
2 |
3 | /**
4 | * Created by krzysiek on 29/11/15.
5 | */
6 | public class Hour24ToHour12Converter implements EmulatorDataConverter {
7 |
8 | @Override
9 | public Object convert(Object value) {
10 | if (!(value instanceof Integer)) {
11 | return 0;
12 | }
13 | int v = ((Integer) value) % 12;
14 | return v == 0 ? 12 : v;
15 | }
16 | }
--------------------------------------------------------------------------------
/app/src/main/java/com/althink/android/ossw/watchsets/DataSourceResolutionContext.java:
--------------------------------------------------------------------------------
1 | package com.althink.android.ossw.watchsets;
2 |
3 | /**
4 | * Created by krzysiek on 17/11/15.
5 | */
6 | public class DataSourceResolutionContext {
7 | public DataSourceType dataSourceType;
8 | public int dataRange;
9 | public ValueResolver resolver;
10 | public ScreenContext screenContext;
11 |
12 | public DataSourceResolutionContext(ScreenContext screenContext) {
13 | this.screenContext = screenContext;
14 | }
15 | }
16 |
--------------------------------------------------------------------------------
/app/src/main/java/com/althink/android/ossw/emulator/source/converter/Hour24ToHour12PeriodConverter.java:
--------------------------------------------------------------------------------
1 | package com.althink.android.ossw.emulator.source.converter;
2 |
3 | /**
4 | * Created by krzysiek on 29/11/15.
5 | */
6 | public class Hour24ToHour12PeriodConverter implements EmulatorDataConverter {
7 |
8 | @Override
9 | public Object convert(Object value) {
10 | if (!(value instanceof Integer)) {
11 | return 0;
12 | }
13 | int v = ((Integer) value);
14 | return v / 12;
15 | }
16 | }
17 |
--------------------------------------------------------------------------------
/app/src/main/java/com/althink/android/ossw/watchsets/field/FieldDefinition.java:
--------------------------------------------------------------------------------
1 | package com.althink.android.ossw.watchsets.field;
2 |
3 | import com.althink.android.ossw.watchsets.ValueResolver;
4 |
5 | /**
6 | * Created by krzysiek on 21/11/15.
7 | */
8 | public abstract class FieldDefinition implements ValueResolver {
9 |
10 | protected int fieldId;
11 |
12 | public FieldDefinition(int fieldId) {
13 | this.fieldId = fieldId;
14 | }
15 |
16 | public int getFieldId() {
17 | return fieldId;
18 | }
19 | }
20 |
--------------------------------------------------------------------------------
/app/src/main/java/com/althink/android/ossw/emulator/source/converter/TimeToRoundedHour24Converter.java:
--------------------------------------------------------------------------------
1 | package com.althink.android.ossw.emulator.source.converter;
2 |
3 | /**
4 | * Created by krzysiek on 29/11/15.
5 | */
6 | public class TimeToRoundedHour24Converter implements EmulatorDataConverter {
7 |
8 | @Override
9 | public Object convert(Object value) {
10 | if (!(value instanceof Integer)) {
11 | return 0;
12 | }
13 | int v = (Integer) value;
14 | return ((v / 60) + 29) / 60;
15 | }
16 | }
17 |
--------------------------------------------------------------------------------
/app/src/main/java/com/althink/android/ossw/emulator/fonts/CharInfo.java:
--------------------------------------------------------------------------------
1 | package com.althink.android.ossw.emulator.fonts;
2 |
3 | /**
4 | * Created by krzysiek on 05/07/15.
5 | */
6 | public class CharInfo {
7 |
8 | private int width;
9 | private int offset;
10 |
11 | public CharInfo(int width, int offset) {
12 | this.width = width;
13 | this.offset = offset;
14 | }
15 |
16 | public int getWidth() {
17 | return width;
18 | }
19 |
20 | public int getOffset() {
21 | return offset;
22 | }
23 | }
24 |
--------------------------------------------------------------------------------
/app/src/main/res/values/dimens.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 | 16dp
5 | 16dp
6 |
7 |
9 | 280dp
10 | 4dp
11 |
12 |
13 |
--------------------------------------------------------------------------------
/app/src/main/java/com/althink/android/ossw/watchsets/EnumToIntResolver.java:
--------------------------------------------------------------------------------
1 | package com.althink.android.ossw.watchsets;
2 |
3 | import java.util.Map;
4 |
5 | /**
6 | * Created by krzysiek on 21/11/15.
7 | */
8 | public class EnumToIntResolver implements ValueResolver {
9 |
10 | private Map valuesMap;
11 |
12 | public EnumToIntResolver(Map valuesMap) {
13 | this.valuesMap = valuesMap;
14 | }
15 |
16 | @Override
17 | public Object resolve(Object value) {
18 | return valuesMap.get(value);
19 | }
20 | }
21 |
--------------------------------------------------------------------------------
/app/src/main/java/com/althink/android/ossw/emulator/model/EmulatorModelProperty.java:
--------------------------------------------------------------------------------
1 | package com.althink.android.ossw.emulator.model;
2 |
3 | import com.althink.android.ossw.emulator.renderer.EmulatorExecutionContext;
4 |
5 | /**
6 | * Created by krzysiek on 22/11/15.
7 | */
8 | public interface EmulatorModelProperty {
9 |
10 | void initialize();
11 |
12 | void add(Object value);
13 |
14 | void subtract(Object value);
15 |
16 | void increment();
17 |
18 | void decrement();
19 |
20 | Object getValue();
21 |
22 | void setValue(Object value);
23 | }
24 |
--------------------------------------------------------------------------------
/app/src/main/java/com/althink/android/ossw/emulator/source/converter/TimeToFiveMinutesRoundedTimeConverter.java:
--------------------------------------------------------------------------------
1 | package com.althink.android.ossw.emulator.source.converter;
2 |
3 | /**
4 | * Created by krzysiek on 29/11/15.
5 | */
6 | public class TimeToFiveMinutesRoundedTimeConverter implements EmulatorDataConverter {
7 |
8 | @Override
9 | public Object convert(Object value) {
10 | if (!(value instanceof Integer)) {
11 | return 0;
12 | }
13 | int v = (Integer) value;
14 | return (((v + 150) / 300) % 288) * 300;
15 | }
16 | }
17 |
--------------------------------------------------------------------------------
/app/src/main/java/com/althink/android/ossw/emulator/source/converter/MinutesToPastToMinutesConverter.java:
--------------------------------------------------------------------------------
1 | package com.althink.android.ossw.emulator.source.converter;
2 |
3 | /**
4 | * Created by krzysiek on 29/11/15.
5 | */
6 | public class MinutesToPastToMinutesConverter implements EmulatorDataConverter {
7 |
8 | @Override
9 | public Object convert(Object value) {
10 | if (!(value instanceof Integer)) {
11 | return 0;
12 | }
13 | int v = (Integer) value;
14 | if (v > 30) {
15 | return 60 - v;
16 | }
17 | return v;
18 | }
19 | }
20 |
--------------------------------------------------------------------------------
/app/src/main/java/com/althink/android/ossw/notifications/model/SimpleListItem.java:
--------------------------------------------------------------------------------
1 | package com.althink.android.ossw.notifications.model;
2 |
3 | /**
4 | * Created by krzysiek on 25/07/15.
5 | */
6 | public class SimpleListItem {
7 | private String text;
8 |
9 | public SimpleListItem(String text) {
10 | this.text = text;
11 | }
12 |
13 | public String getText() {
14 | return text;
15 | }
16 |
17 | @Override
18 | public String toString() {
19 | return "SimpleListItem{" +
20 | "text='" + text + '\'' +
21 | '}';
22 | }
23 | }
24 |
--------------------------------------------------------------------------------
/.idea/runConfigurations.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
11 |
12 |
--------------------------------------------------------------------------------
/app/src/main/res/layout/drawer_header.xml:
--------------------------------------------------------------------------------
1 |
2 |
9 |
14 |
--------------------------------------------------------------------------------
/app/src/main/java/com/althink/android/ossw/emulator/actions/EmulatorEventHandler.java:
--------------------------------------------------------------------------------
1 | package com.althink.android.ossw.emulator.actions;
2 |
3 | /**
4 | * Created by krzysiek on 22/11/15.
5 | */
6 | public class EmulatorEventHandler {
7 | private int eventId;
8 | private EmulatorAction action;
9 |
10 | public EmulatorEventHandler(int eventId, EmulatorAction action) {
11 | this.action = action;
12 | this.eventId = eventId;
13 | }
14 |
15 | public EmulatorAction getAction() {
16 | return action;
17 | }
18 |
19 | public int getEventId() {
20 | return eventId;
21 | }
22 | }
23 |
--------------------------------------------------------------------------------
/app/src/main/java/com/althink/android/ossw/emulator/source/internal/ZeroDataSource.java:
--------------------------------------------------------------------------------
1 | package com.althink.android.ossw.emulator.source.internal;
2 |
3 | import com.althink.android.ossw.emulator.renderer.EmulatorExecutionContext;
4 | import com.althink.android.ossw.emulator.source.EmulatorDataSource;
5 | import com.althink.android.ossw.watchsets.DataSourceType;
6 |
7 | /**
8 | * Created by krzysiek on 06/07/15.
9 | */
10 | public class ZeroDataSource implements EmulatorDataSource {
11 | @Override
12 | public Object getData(DataSourceType type, int range, EmulatorExecutionContext ctx) {
13 | return 0;
14 | }
15 | }
16 |
--------------------------------------------------------------------------------
/app/src/main/java/com/althink/android/ossw/notifications/model/Notification.java:
--------------------------------------------------------------------------------
1 | package com.althink.android.ossw.notifications.model;
2 |
3 | import java.util.Date;
4 | import java.util.List;
5 |
6 | /**
7 | * Created by krzysiek on 24/07/15.
8 | */
9 | public interface Notification extends Comparable {
10 | String getId();
11 | NotificationType getType();
12 | NotificationCategory getCategory();
13 | String getApplication();
14 | Date getDate();
15 | List getOperations();
16 | Integer getExternalId();
17 | void setExternalId(Integer externalId);
18 | Object getNotificationObject();
19 | }
20 |
--------------------------------------------------------------------------------
/app/src/main/java/com/althink/android/ossw/emulator/source/converter/MinutesToPastToDesignatorConverter.java:
--------------------------------------------------------------------------------
1 | package com.althink.android.ossw.emulator.source.converter;
2 |
3 | /**
4 | * Created by krzysiek on 29/11/15.
5 | */
6 | public class MinutesToPastToDesignatorConverter implements EmulatorDataConverter {
7 |
8 | @Override
9 | public Object convert(Object value) {
10 | if (!(value instanceof Integer)) {
11 | return 0;
12 | }
13 | int v = (Integer) value;
14 | if (v > 30) {
15 | return 2;
16 | } else if (v == 0) {
17 | return 0;
18 | } else {
19 | return 1;
20 | }
21 | }
22 | }
23 |
--------------------------------------------------------------------------------
/app/src/main/java/com/althink/android/ossw/emulator/source/internal/MacAddressInternalEmulatorDataSource.java:
--------------------------------------------------------------------------------
1 | package com.althink.android.ossw.emulator.source.internal;
2 |
3 | import com.althink.android.ossw.emulator.renderer.EmulatorExecutionContext;
4 | import com.althink.android.ossw.emulator.source.EmulatorDataSource;
5 | import com.althink.android.ossw.watchsets.DataSourceType;
6 |
7 | /**
8 | * Created by krzysiek on 05/12/15.
9 | */
10 | public class MacAddressInternalEmulatorDataSource implements EmulatorDataSource {
11 |
12 | @Override
13 | public Object getData(DataSourceType type, int range, EmulatorExecutionContext ctx) {
14 | return "XX:XX:XX:XX:XX:XX";
15 | }
16 | }
17 |
--------------------------------------------------------------------------------
/app/src/main/java/com/althink/android/ossw/db/WatchSetInfo.java:
--------------------------------------------------------------------------------
1 | package com.althink.android.ossw.db;
2 |
3 | /**
4 | * Created by krzysiek on 04/07/15.
5 | */
6 | public class WatchSetInfo {
7 | private Integer id;
8 | private String name;
9 |
10 | public WatchSetInfo(Integer id, String name) {
11 | this.id = id;
12 | this.name = name;
13 | }
14 |
15 | public Integer getId() {
16 | return id;
17 | }
18 |
19 | public void setId(Integer id) {
20 | this.id = id;
21 | }
22 |
23 | public String getName() {
24 | return name;
25 | }
26 |
27 | public void setName(String name) {
28 | this.name = name;
29 | }
30 | }
31 |
--------------------------------------------------------------------------------
/app/src/main/java/com/althink/android/ossw/emulator/source/internal/FirmwareVersionInternalEmulatorDataSource.java:
--------------------------------------------------------------------------------
1 | package com.althink.android.ossw.emulator.source.internal;
2 |
3 | import com.althink.android.ossw.emulator.renderer.EmulatorExecutionContext;
4 | import com.althink.android.ossw.emulator.source.EmulatorDataSource;
5 | import com.althink.android.ossw.watchsets.DataSourceType;
6 |
7 | /**
8 | * Created by krzysiek on 05/12/15.
9 | */
10 | public class FirmwareVersionInternalEmulatorDataSource implements EmulatorDataSource {
11 |
12 | @Override
13 | public Object getData(DataSourceType type, int range, EmulatorExecutionContext ctx) {
14 | return "x.x.x-s1x0";
15 | }
16 | }
17 |
--------------------------------------------------------------------------------
/app/src/main/java/com/althink/android/ossw/watchsets/field/IntegerFieldDefinition.java:
--------------------------------------------------------------------------------
1 | package com.althink.android.ossw.watchsets.field;
2 |
3 | /**
4 | * Created by krzysiek on 21/11/15.
5 | */
6 | public class IntegerFieldDefinition extends FieldDefinition {
7 |
8 | public IntegerFieldDefinition(int fieldId) {
9 | super(fieldId);
10 | }
11 |
12 | @Override
13 | public Object resolve(Object value) {
14 | if (value instanceof String) {
15 | return Integer.parseInt((String) value);
16 | } else if (value instanceof Integer) {
17 | return (Integer) value;
18 | } else {
19 | return null;
20 | }
21 | }
22 |
23 | }
24 |
--------------------------------------------------------------------------------
/app/src/main/java/com/althink/android/ossw/notifications/parser/api18/DefaultTicker.java:
--------------------------------------------------------------------------------
1 | //package com.althink.android.ossw.notifications.model.api19;
2 | //
3 | //import android.app.Notification;
4 | //
5 | //public class DefaultTicker implements MessageParser {
6 | // @Override
7 | // public Message parse(Notification notification) {
8 | // Message result = new Message();
9 | //
10 | // String ticker = notification.tickerText.toString();
11 | //
12 | // int indexDelimiter = ticker.indexOf(':');
13 | //
14 | // if (indexDelimiter == -1)
15 | // return null;
16 | //
17 | // result.subject = ticker.substring(0, indexDelimiter);
18 | // result.message = ticker.substring(indexDelimiter + 2);
19 | //
20 | // return result;
21 | // }
22 | //}
23 |
--------------------------------------------------------------------------------
/app/proguard-rules.pro:
--------------------------------------------------------------------------------
1 | # Add project specific ProGuard rules here.
2 | # By default, the flags in this file are appended to flags specified
3 | # in /Users/krzysiek/Library/Android/sdk/tools/proguard/proguard-android.txt
4 | # You can edit the include path and order by changing the proguardFiles
5 | # directive in build.gradle.
6 | #
7 | # For more details, see
8 | # http://developer.android.com/guide/developing/tools/proguard.html
9 |
10 | # Add any project specific keep options here:
11 |
12 | # If your project uses WebView with JS, uncomment the following
13 | # and specify the fully qualified class name to the JavaScript interface
14 | # class:
15 | #-keepclassmembers class fqcn.of.javascript.interface.for.webview {
16 | # public *;
17 | #}
18 |
--------------------------------------------------------------------------------
/app/src/main/java/com/althink/android/ossw/plugins/PluginFunctionDefinition.java:
--------------------------------------------------------------------------------
1 | package com.althink.android.ossw.plugins;
2 |
3 | /**
4 | * Created by krzysiek on 16/06/15.
5 | */
6 | public class PluginFunctionDefinition {
7 | private int id;
8 | private String name;
9 | private String description;
10 |
11 | public PluginFunctionDefinition(int id, String name, String description) {
12 | this.id = id;
13 | this.name = name;
14 | this.description = description;
15 | }
16 |
17 | public int getId() {
18 | return id;
19 | }
20 |
21 | public String getName() {
22 | return name;
23 | }
24 |
25 | public String getDescription() {
26 | return description;
27 | }
28 | }
29 |
--------------------------------------------------------------------------------
/app/src/main/java/com/althink/android/ossw/emulator/actions/EmulatorCompoundAction.java:
--------------------------------------------------------------------------------
1 | package com.althink.android.ossw.emulator.actions;
2 |
3 | import com.althink.android.ossw.emulator.renderer.EmulatorExecutionContext;
4 |
5 | import java.util.List;
6 |
7 | /**
8 | * Created by krzysiek on 22/11/15.
9 | */
10 | public class EmulatorCompoundAction implements EmulatorAction {
11 |
12 | private List actions;
13 |
14 | public EmulatorCompoundAction(List actions) {
15 | this.actions = actions;
16 | }
17 |
18 | @Override
19 | public void performAction(EmulatorExecutionContext ctx) {
20 | for (EmulatorAction action : actions) {
21 | action.performAction(ctx);
22 | }
23 | }
24 | }
25 |
--------------------------------------------------------------------------------
/.idea/gradle.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
8 |
9 |
10 |
11 |
12 |
13 |
14 |
15 |
16 |
17 |
18 |
19 |
--------------------------------------------------------------------------------
/.idea/compiler.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
8 |
9 |
10 |
11 |
12 |
13 |
14 |
15 |
16 |
17 |
18 |
19 |
20 |
21 |
22 |
--------------------------------------------------------------------------------
/app/src/main/java/com/althink/android/ossw/emulator/fonts/CharInfoLookup.java:
--------------------------------------------------------------------------------
1 | package com.althink.android.ossw.emulator.fonts;
2 |
3 | /**
4 | * Created by krzysiek on 05/07/15.
5 | */
6 | public class CharInfoLookup {
7 | private char minChar;
8 | private char maxChar;
9 | private CharInfo[] charTable;
10 |
11 | public CharInfoLookup(char minChar, char maxChar, CharInfo[] charTable) {
12 | this.minChar = minChar;
13 | this.maxChar = maxChar;
14 | this.charTable = charTable;
15 | }
16 |
17 | public char getMinChar() {
18 | return minChar;
19 | }
20 |
21 | public char getMaxChar() {
22 | return maxChar;
23 | }
24 |
25 | public CharInfo[] getCharTable() {
26 | return charTable;
27 | }
28 | }
29 |
--------------------------------------------------------------------------------
/app/src/main/res/values/colors.xml:
--------------------------------------------------------------------------------
1 |
2 | #15CAB1
3 | #424242
4 | #FF6D00
5 | #00695C
6 | #FFF
7 | #FFF
8 | #212121
9 | #000
10 | #15CAB1
11 | #777
12 |
13 | #a0f5e9
14 | #d5fbf5
15 | #d5fbf5
16 |
--------------------------------------------------------------------------------
/app/src/main/java/com/althink/android/ossw/emulator/source/internal/BatteryLevelInternalEmulatorDataSource.java:
--------------------------------------------------------------------------------
1 | package com.althink.android.ossw.emulator.source.internal;
2 |
3 | import com.althink.android.ossw.emulator.renderer.EmulatorExecutionContext;
4 | import com.althink.android.ossw.emulator.source.EmulatorDataSource;
5 | import com.althink.android.ossw.watchsets.DataSourceType;
6 |
7 | import java.util.Calendar;
8 |
9 | /**
10 | * Created by krzysiek on 14/06/15.
11 | */
12 | public class BatteryLevelInternalEmulatorDataSource implements EmulatorDataSource {
13 |
14 | @Override
15 | public Object getData(DataSourceType type, int range, EmulatorExecutionContext ctx) {
16 | if(!DataSourceType.NUMBER.equals(type)) {
17 | return null;
18 | }
19 | return 100;
20 | }
21 | }
22 |
--------------------------------------------------------------------------------
/app/src/main/java/com/althink/android/ossw/service/ble/BleConnectionStatus.java:
--------------------------------------------------------------------------------
1 | package com.althink.android.ossw.service.ble;
2 |
3 | import com.althink.android.ossw.R;
4 | import com.althink.android.ossw.service.OsswService;
5 |
6 | /**
7 | * Created by krzysiek on 10/10/15.
8 | * vaspa: Add resource id for internationalization
9 | */
10 | public enum BleConnectionStatus {
11 | DISCONNECTED(R.string.disconnected),
12 | CONNECTING(R.string.connecting),
13 | CONNECTED(R.string.connected),
14 | AUTO_RECONNECT(R.string.auto_reconnect);
15 | private int stringId;
16 |
17 | BleConnectionStatus(int sId) {
18 | stringId = sId;
19 | }
20 |
21 | @Override
22 | public String toString() {
23 | return OsswService.getInstance().getApplicationContext().getString(stringId);
24 | }
25 | }
26 |
--------------------------------------------------------------------------------
/app/src/main/java/com/althink/android/ossw/watchsets/field/EnumFieldDefinition.java:
--------------------------------------------------------------------------------
1 | package com.althink.android.ossw.watchsets.field;
2 |
3 | import java.util.Map;
4 |
5 | /**
6 | * Created by krzysiek on 21/11/15.
7 | */
8 | public class EnumFieldDefinition extends FieldDefinition {
9 |
10 | private Map values;
11 |
12 | public EnumFieldDefinition(int fieldId, Map values) {
13 | super(fieldId);
14 | this.values = values;
15 | }
16 |
17 | public Integer getValueKey(String value) {
18 | return values.get(value);
19 | }
20 |
21 | @Override
22 | public Object resolve(Object value) {
23 | if (value instanceof String) {
24 | return values.get(value);
25 | } else {
26 | return null;
27 | }
28 | }
29 | }
30 |
--------------------------------------------------------------------------------
/app/src/main/java/com/althink/android/ossw/emulator/source/EmulatorAttachedResourceSource.java:
--------------------------------------------------------------------------------
1 | package com.althink.android.ossw.emulator.source;
2 |
3 | import com.althink.android.ossw.emulator.watchset.WatchSetEmulatorModel;
4 | import com.althink.android.ossw.watchsets.CompiledWatchSet;
5 |
6 | /**
7 | * Created by krzysiek on 08/09/15.
8 | */
9 | public class EmulatorAttachedResourceSource implements EmulatorResourceSource {
10 |
11 | private WatchSetEmulatorModel watchSet;
12 | private int resourceId;
13 |
14 | public EmulatorAttachedResourceSource(WatchSetEmulatorModel watchSet, int resourceId) {
15 | this.watchSet = watchSet;
16 | this.resourceId = resourceId;
17 | }
18 |
19 | @Override
20 | public byte[] getData() {
21 | return watchSet.getResources().get(resourceId);
22 | }
23 | }
24 |
--------------------------------------------------------------------------------
/app/src/main/java/com/althink/android/ossw/emulator/source/internal/YearInternalEmulatorDataSource.java:
--------------------------------------------------------------------------------
1 | package com.althink.android.ossw.emulator.source.internal;
2 |
3 | import com.althink.android.ossw.emulator.renderer.EmulatorExecutionContext;
4 | import com.althink.android.ossw.emulator.source.EmulatorDataSource;
5 | import com.althink.android.ossw.watchsets.DataSourceType;
6 |
7 | import java.util.Calendar;
8 |
9 | /**
10 | * Created by krzysiek on 14/06/15.
11 | */
12 | public class YearInternalEmulatorDataSource implements EmulatorDataSource {
13 |
14 | @Override
15 | public Object getData(DataSourceType type, int range, EmulatorExecutionContext ctx) {
16 | if(!DataSourceType.NUMBER.equals(type)) {
17 | return null;
18 | }
19 | return Calendar.getInstance().get(Calendar.YEAR);
20 | }
21 | }
22 |
--------------------------------------------------------------------------------
/app/src/main/java/com/althink/android/ossw/emulator/control/AbstractEmulatorControl.java:
--------------------------------------------------------------------------------
1 | package com.althink.android.ossw.emulator.control;
2 |
3 | import com.althink.android.ossw.emulator.renderer.EmulatorExecutionContext;
4 | import com.althink.android.ossw.emulator.source.EmulatorDataSource;
5 | import com.althink.android.ossw.watchsets.DataSourceType;
6 |
7 | /**
8 | * Created by krzysiek on 14/06/15.
9 | */
10 | public abstract class AbstractEmulatorControl implements EmulatorControl {
11 |
12 | private EmulatorDataSource dataSource;
13 |
14 | protected AbstractEmulatorControl(EmulatorDataSource dataSource) {
15 | this.dataSource = dataSource;
16 | }
17 |
18 | protected Object getData(DataSourceType type, int range, EmulatorExecutionContext ctx) {
19 | return dataSource.getData(type, range, ctx);
20 | }
21 | }
22 |
--------------------------------------------------------------------------------
/app/src/main/java/com/althink/android/ossw/emulator/source/internal/MonthInternalEmulatorDataSource.java:
--------------------------------------------------------------------------------
1 | package com.althink.android.ossw.emulator.source.internal;
2 |
3 | import com.althink.android.ossw.emulator.renderer.EmulatorExecutionContext;
4 | import com.althink.android.ossw.emulator.source.EmulatorDataSource;
5 | import com.althink.android.ossw.watchsets.DataSourceType;
6 |
7 | import java.util.Calendar;
8 |
9 | /**
10 | * Created by krzysiek on 14/06/15.
11 | */
12 | public class MonthInternalEmulatorDataSource implements EmulatorDataSource {
13 |
14 | @Override
15 | public Object getData(DataSourceType type, int range, EmulatorExecutionContext ctx) {
16 | if(!DataSourceType.NUMBER.equals(type)) {
17 | return null;
18 | }
19 | return Calendar.getInstance().get(Calendar.MONTH) + 1;
20 | }
21 | }
22 |
--------------------------------------------------------------------------------
/app/src/main/java/com/althink/android/ossw/notifications/model/Operation.java:
--------------------------------------------------------------------------------
1 | package com.althink.android.ossw.notifications.model;
2 |
3 | import android.app.PendingIntent;
4 |
5 | /**
6 | * Created by krzysiek on 24/07/15.
7 | */
8 | public class Operation {
9 | String title;
10 | PendingIntent intent;
11 |
12 | public Operation(String title, PendingIntent intent) {
13 | this.title = title;
14 | this.intent = intent;
15 | }
16 |
17 | public String getTitle() {
18 | return title;
19 | }
20 |
21 | public PendingIntent getIntent() {
22 | return intent;
23 | }
24 |
25 | @Override
26 | public String toString() {
27 | return "Operation{" +
28 | "title='" + title + '\'' +
29 | ", intent=" + intent +
30 | '}';
31 | }
32 | }
33 |
--------------------------------------------------------------------------------
/app/src/main/java/com/althink/android/ossw/emulator/source/internal/Hour24InternalEmulatorDataSource.java:
--------------------------------------------------------------------------------
1 | package com.althink.android.ossw.emulator.source.internal;
2 |
3 | import com.althink.android.ossw.emulator.renderer.EmulatorExecutionContext;
4 | import com.althink.android.ossw.emulator.source.EmulatorDataSource;
5 | import com.althink.android.ossw.watchsets.DataSourceType;
6 |
7 | import java.util.Calendar;
8 |
9 | /**
10 | * Created by krzysiek on 14/06/15.
11 | */
12 | public class Hour24InternalEmulatorDataSource implements EmulatorDataSource {
13 |
14 | @Override
15 | public Object getData(DataSourceType type, int range, EmulatorExecutionContext ctx) {
16 | if(!DataSourceType.NUMBER.equals(type)) {
17 | return null;
18 | }
19 | return Calendar.getInstance().get(Calendar.HOUR_OF_DAY);
20 | }
21 | }
22 |
--------------------------------------------------------------------------------
/app/src/main/java/com/althink/android/ossw/emulator/source/internal/MinutesInternalEmulatorDataSource.java:
--------------------------------------------------------------------------------
1 | package com.althink.android.ossw.emulator.source.internal;
2 |
3 | import com.althink.android.ossw.emulator.renderer.EmulatorExecutionContext;
4 | import com.althink.android.ossw.emulator.source.EmulatorDataSource;
5 | import com.althink.android.ossw.watchsets.DataSourceType;
6 |
7 | import java.util.Calendar;
8 |
9 | /**
10 | * Created by krzysiek on 14/06/15.
11 | */
12 | public class MinutesInternalEmulatorDataSource implements EmulatorDataSource {
13 |
14 | @Override
15 | public Object getData(DataSourceType type, int range, EmulatorExecutionContext ctx) {
16 | if(!DataSourceType.NUMBER.equals(type)) {
17 | return null;
18 | }
19 | return Calendar.getInstance().get(Calendar.MINUTE);
20 | }
21 | }
22 |
--------------------------------------------------------------------------------
/app/src/main/java/com/althink/android/ossw/emulator/source/internal/SecondsInternalEmulatorDataSource.java:
--------------------------------------------------------------------------------
1 | package com.althink.android.ossw.emulator.source.internal;
2 |
3 | import com.althink.android.ossw.emulator.renderer.EmulatorExecutionContext;
4 | import com.althink.android.ossw.emulator.source.EmulatorDataSource;
5 | import com.althink.android.ossw.watchsets.DataSourceType;
6 |
7 | import java.util.Calendar;
8 |
9 | /**
10 | * Created by krzysiek on 14/06/15.
11 | */
12 | public class SecondsInternalEmulatorDataSource implements EmulatorDataSource {
13 |
14 | @Override
15 | public Object getData(DataSourceType type, int range, EmulatorExecutionContext ctx) {
16 | if(!DataSourceType.NUMBER.equals(type)) {
17 | return null;
18 | }
19 | return Calendar.getInstance().get(Calendar.SECOND);
20 | }
21 | }
22 |
--------------------------------------------------------------------------------
/app/src/main/java/com/althink/android/ossw/emulator/source/internal/DayOfWeekInternalEmulatorDataSource.java:
--------------------------------------------------------------------------------
1 | package com.althink.android.ossw.emulator.source.internal;
2 |
3 | import com.althink.android.ossw.emulator.renderer.EmulatorExecutionContext;
4 | import com.althink.android.ossw.emulator.source.EmulatorDataSource;
5 | import com.althink.android.ossw.watchsets.DataSourceType;
6 |
7 | import java.util.Calendar;
8 |
9 | /**
10 | * Created by krzysiek on 14/06/15.
11 | */
12 | public class DayOfWeekInternalEmulatorDataSource implements EmulatorDataSource {
13 |
14 | @Override
15 | public Object getData(DataSourceType type, int range, EmulatorExecutionContext ctx) {
16 | if(!DataSourceType.NUMBER.equals(type)) {
17 | return null;
18 | }
19 | return Calendar.getInstance().get(Calendar.DAY_OF_WEEK);
20 | }
21 | }
22 |
--------------------------------------------------------------------------------
/app/src/main/java/com/althink/android/ossw/emulator/source/internal/DayOfYearInternalEmulatorDataSource.java:
--------------------------------------------------------------------------------
1 | package com.althink.android.ossw.emulator.source.internal;
2 |
3 | import com.althink.android.ossw.emulator.renderer.EmulatorExecutionContext;
4 | import com.althink.android.ossw.emulator.source.EmulatorDataSource;
5 | import com.althink.android.ossw.watchsets.DataSourceType;
6 |
7 | import java.util.Calendar;
8 |
9 | /**
10 | * Created by krzysiek on 14/06/15.
11 | */
12 | public class DayOfYearInternalEmulatorDataSource implements EmulatorDataSource {
13 |
14 | @Override
15 | public Object getData(DataSourceType type, int range, EmulatorExecutionContext ctx) {
16 | if(!DataSourceType.NUMBER.equals(type)) {
17 | return null;
18 | }
19 | return Calendar.getInstance().get(Calendar.DAY_OF_YEAR);
20 | }
21 | }
22 |
--------------------------------------------------------------------------------
/app/src/main/java/com/althink/android/ossw/emulator/source/internal/DayOfMonthInternalEmulatorDataSource.java:
--------------------------------------------------------------------------------
1 | package com.althink.android.ossw.emulator.source.internal;
2 |
3 | import com.althink.android.ossw.emulator.renderer.EmulatorExecutionContext;
4 | import com.althink.android.ossw.emulator.source.EmulatorDataSource;
5 | import com.althink.android.ossw.watchsets.DataSourceType;
6 |
7 | import java.util.Calendar;
8 |
9 | /**
10 | * Created by krzysiek on 14/06/15.
11 | */
12 | public class DayOfMonthInternalEmulatorDataSource implements EmulatorDataSource {
13 |
14 | @Override
15 | public Object getData(DataSourceType type, int range, EmulatorExecutionContext ctx) {
16 | if(!DataSourceType.NUMBER.equals(type)) {
17 | return null;
18 | }
19 | return Calendar.getInstance().get(Calendar.DAY_OF_MONTH);
20 | }
21 | }
22 |
--------------------------------------------------------------------------------
/app/src/main/java/com/althink/android/ossw/notifications/model/SubjectMessageItem.java:
--------------------------------------------------------------------------------
1 | package com.althink.android.ossw.notifications.model;
2 |
3 | /**
4 | * Created by krzysiek on 25/07/15.
5 | */
6 | public class SubjectMessageItem {
7 | private String subject;
8 | private String message;
9 |
10 | public SubjectMessageItem(String subject, String message) {
11 | this.subject = subject;
12 | this.message = message;
13 | }
14 |
15 | public String getSubject() {
16 | return subject;
17 | }
18 |
19 | public String getMessage() {
20 | return message;
21 | }
22 |
23 | @Override
24 | public String toString() {
25 | return "SubjectMessageItem{" +
26 | "subject='" + subject + '\'' +
27 | ", message='" + message + '\'' +
28 | '}';
29 | }
30 | }
31 |
--------------------------------------------------------------------------------
/app/src/main/java/com/althink/android/ossw/emulator/source/internal/Hour12DesignatorInternalEmulatorDataSource.java:
--------------------------------------------------------------------------------
1 | package com.althink.android.ossw.emulator.source.internal;
2 |
3 | import com.althink.android.ossw.emulator.renderer.EmulatorExecutionContext;
4 | import com.althink.android.ossw.emulator.source.EmulatorDataSource;
5 | import com.althink.android.ossw.watchsets.DataSourceType;
6 |
7 | import java.util.Calendar;
8 |
9 | /**
10 | * Created by krzysiek on 14/06/15.
11 | */
12 | public class Hour12DesignatorInternalEmulatorDataSource implements EmulatorDataSource {
13 |
14 | @Override
15 | public Object getData(DataSourceType type, int range, EmulatorExecutionContext ctx) {
16 | if (!DataSourceType.NUMBER.equals(type)) {
17 | return null;
18 | }
19 | return (int) Calendar.getInstance().get(Calendar.HOUR_OF_DAY) /12;
20 | }
21 | }
22 |
--------------------------------------------------------------------------------
/app/src/main/java/com/althink/android/ossw/emulator/source/internal/Hour12InternalEmulatorDataSource.java:
--------------------------------------------------------------------------------
1 | package com.althink.android.ossw.emulator.source.internal;
2 |
3 | import com.althink.android.ossw.emulator.renderer.EmulatorExecutionContext;
4 | import com.althink.android.ossw.emulator.source.EmulatorDataSource;
5 | import com.althink.android.ossw.watchsets.DataSourceType;
6 |
7 | import java.util.Calendar;
8 |
9 | /**
10 | * Created by krzysiek on 14/06/15.
11 | */
12 | public class Hour12InternalEmulatorDataSource implements EmulatorDataSource {
13 |
14 | @Override
15 | public Object getData(DataSourceType type, int range, EmulatorExecutionContext ctx) {
16 | if(!DataSourceType.NUMBER.equals(type)) {
17 | return null;
18 | }
19 | int h = Calendar.getInstance().get(Calendar.HOUR_OF_DAY) % 12;
20 | return h == 0 ? 12 : h;
21 | }
22 | }
23 |
--------------------------------------------------------------------------------
/.travis.yml:
--------------------------------------------------------------------------------
1 | language: android
2 | android:
3 | components:
4 | # Uncomment the lines below if you want to
5 | # use the latest revision of Android SDK Tools
6 | - platform-tools
7 | - tools
8 |
9 | # The BuildTools version used by your project
10 | - build-tools-23.0.2
11 |
12 | # The SDK version used to compile your project
13 | - android-23
14 |
15 | # Additional components
16 | #- extra-google-google_play_services
17 | - extra-google-m2repository
18 | - extra-android-m2repository
19 | #- addon-google_apis-google-19
20 |
21 | # Specify at least one system image,
22 | # if you need to run emulator(s) during your tests
23 | #- sys-img-armeabi-v7a-android-19
24 | #- sys-img-x86-android-17
25 | script:
26 | - ./gradlew assemble lint
27 | after_failure:
28 | - cat /home/travis/build/ossw/ossw-android/app/build/outputs/lint-results.xml
29 |
--------------------------------------------------------------------------------
/app/src/main/java/com/althink/android/ossw/emulator/renderer/EmulatorExecutionContext.java:
--------------------------------------------------------------------------------
1 | package com.althink.android.ossw.emulator.renderer;
2 |
3 | import com.althink.android.ossw.emulator.WatchEmulator;
4 | import com.althink.android.ossw.emulator.watchset.WatchSetEmulatorModel;
5 |
6 | /**
7 | * Created by krzysiek on 22/11/15.
8 | */
9 | public class EmulatorExecutionContext extends WatchEmulator {
10 |
11 | private WatchSetEmulatorModel watchset;
12 | private WatchEmulator emulator;
13 |
14 | public EmulatorExecutionContext(WatchSetEmulatorModel watchset, WatchEmulator emulator) {
15 | super();
16 | this.watchset = watchset;
17 | this.emulator = emulator;
18 | }
19 |
20 | public WatchEmulator getEmulator() {
21 | return emulator;
22 | }
23 |
24 | public WatchSetEmulatorModel getWatchset() {
25 | return watchset;
26 | }
27 | }
28 |
--------------------------------------------------------------------------------
/app/src/main/java/com/althink/android/ossw/service/WatchOperationContext.java:
--------------------------------------------------------------------------------
1 | package com.althink.android.ossw.service;
2 |
3 | import java.util.List;
4 |
5 | /**
6 | * Created by krzysiek on 14/06/15.
7 | */
8 | public class WatchOperationContext {
9 |
10 | private List externalParameters;
11 | private List externalFunctions;
12 |
13 | public WatchOperationContext(List externalParameters, List externalFunctions) {
14 | this.externalParameters = externalParameters;
15 | this.externalFunctions = externalFunctions;
16 | }
17 |
18 | public List getExternalParameters() {
19 | return externalParameters;
20 | }
21 |
22 | public List getExternalFunctions() {
23 | return externalFunctions;
24 | }
25 |
26 | }
27 |
--------------------------------------------------------------------------------
/gradle.properties:
--------------------------------------------------------------------------------
1 | # Project-wide Gradle settings.
2 |
3 | # IDE (e.g. Android Studio) users:
4 | # Gradle settings configured through the IDE *will override*
5 | # any settings specified in this file.
6 |
7 | # For more details on how to configure your build environment visit
8 | # http://www.gradle.org/docs/current/userguide/build_environment.html
9 |
10 | # Specifies the JVM arguments used for the daemon process.
11 | # The setting is particularly useful for tweaking memory settings.
12 | # Default uriValue: -Xmx10248m -XX:MaxPermSize=256m
13 | # org.gradle.jvmargs=-Xmx2048m -XX:MaxPermSize=512m -XX:+HeapDumpOnOutOfMemoryError -Dfile.encoding=UTF-8
14 |
15 | # When configured, Gradle will run in incubating parallel mode.
16 | # This option should only be used with decoupled projects. More details, visit
17 | # http://www.gradle.org/docs/current/userguide/multi_project_builds.html#sec:decoupled_projects
18 | # org.gradle.parallel=true
--------------------------------------------------------------------------------
/app/src/main/res/layout/fragment_plugins.xml:
--------------------------------------------------------------------------------
1 |
6 |
7 |
10 |
11 |
15 |
16 |
21 |
22 |
23 |
24 |
--------------------------------------------------------------------------------
/app/src/main/res/values-sw600dp/template-dimens.xml:
--------------------------------------------------------------------------------
1 |
16 |
17 |
18 |
19 |
20 |
21 | @dimen/margin_huge
22 | @dimen/margin_medium
23 |
24 |
25 |
--------------------------------------------------------------------------------
/app/src/main/java/com/althink/android/ossw/notifications/message/NotificationSummaryMessageBuilder.java:
--------------------------------------------------------------------------------
1 | package com.althink.android.ossw.notifications.message;
2 |
3 | import com.althink.android.ossw.notifications.model.ListNotification;
4 | import com.althink.android.ossw.notifications.model.Notification;
5 |
6 | import java.io.ByteArrayOutputStream;
7 | import java.util.List;
8 |
9 | /**
10 | * Created by krzysiek on 19/07/15.
11 | */
12 | public class NotificationSummaryMessageBuilder implements NotificationMessageBuilder {
13 |
14 | private ByteArrayOutputStream out;
15 |
16 | public NotificationSummaryMessageBuilder(int messagesNo) {
17 | out = new ByteArrayOutputStream();
18 |
19 | if (messagesNo > 255) {
20 | messagesNo = 255;
21 | }
22 | out.write(0);
23 | out.write(messagesNo);
24 | }
25 |
26 | @Override
27 | public byte[] build() {
28 | return out.toByteArray();
29 | }
30 | }
31 |
--------------------------------------------------------------------------------
/app/src/main/java/com/althink/android/ossw/emulator/event/AbstractButtonEmulatorEvent.java:
--------------------------------------------------------------------------------
1 | package com.althink.android.ossw.emulator.event;
2 |
3 | /**
4 | * Created by krzysiek on 14/06/15.
5 | */
6 | public class AbstractButtonEmulatorEvent implements EmulatorEvent {
7 | private EmulatorButton button;
8 |
9 | public AbstractButtonEmulatorEvent(EmulatorButton button) {
10 | this.button = button;
11 | }
12 |
13 | public EmulatorButton getButton() {
14 | return button;
15 | }
16 |
17 | @Override
18 | public boolean equals(Object o) {
19 | if (this == o) return true;
20 | if (o == null || getClass() != o.getClass()) return false;
21 | AbstractButtonEmulatorEvent that = (AbstractButtonEmulatorEvent) o;
22 | if (button != that.button) return false;
23 | return true;
24 | }
25 |
26 | @Override
27 | public int hashCode() {
28 | return button != null ? button.hashCode() : 0;
29 | }
30 | }
31 |
--------------------------------------------------------------------------------
/app/src/main/java/com/althink/android/ossw/emulator/source/EmulatorModelDataSource.java:
--------------------------------------------------------------------------------
1 | package com.althink.android.ossw.emulator.source;
2 |
3 | import com.althink.android.ossw.emulator.model.EmulatorModelProperty;
4 | import com.althink.android.ossw.emulator.renderer.EmulatorExecutionContext;
5 | import com.althink.android.ossw.watchsets.DataSourceType;
6 |
7 | /**
8 | * Created by krzysiek on 22/11/15.
9 | */
10 | public class EmulatorModelDataSource implements EmulatorDataSource {
11 |
12 | private int propertyId;
13 |
14 | public EmulatorModelDataSource(int propertyId) {
15 | this.propertyId = propertyId;
16 | }
17 |
18 | @Override
19 | public Object getData(DataSourceType type, int range, EmulatorExecutionContext ctx) {
20 | EmulatorModelProperty property = ctx.getWatchset().getCurrentScreenModel().get(propertyId);
21 | if (property != null) {
22 | return property.getValue();
23 | }
24 | return null;
25 | }
26 | }
27 |
--------------------------------------------------------------------------------
/app/src/main/res/values-v21/base-template-styles.xml:
--------------------------------------------------------------------------------
1 |
2 |
17 |
18 |
19 |
23 |
24 |
--------------------------------------------------------------------------------
/app/src/main/res/layout/fragment_watchsets.xml:
--------------------------------------------------------------------------------
1 |
6 |
7 |
10 |
11 |
16 |
17 |
23 |
24 |
25 |
26 |
--------------------------------------------------------------------------------
/app/src/main/java/com/althink/android/ossw/emulator/source/internal/TimeInSecondsInternalEmulatorDataSource.java:
--------------------------------------------------------------------------------
1 | package com.althink.android.ossw.emulator.source.internal;
2 |
3 | import com.althink.android.ossw.emulator.renderer.EmulatorExecutionContext;
4 | import com.althink.android.ossw.emulator.source.EmulatorDataSource;
5 | import com.althink.android.ossw.watchsets.DataSourceType;
6 |
7 | import java.util.Calendar;
8 |
9 | /**
10 | * Created by krzysiek on 29/11/15.
11 | */
12 | public class TimeInSecondsInternalEmulatorDataSource implements EmulatorDataSource {
13 |
14 | @Override
15 | public Object getData(DataSourceType type, int range, EmulatorExecutionContext ctx) {
16 | if (!DataSourceType.NUMBER.equals(type)) {
17 | return null;
18 | }
19 | return Calendar.getInstance().get(Calendar.HOUR_OF_DAY) * 3600 +
20 | Calendar.getInstance().get(Calendar.MINUTE) * 60 +
21 | Calendar.getInstance().get(Calendar.SECOND);
22 | }
23 | }
24 |
--------------------------------------------------------------------------------
/app/src/main/java/com/althink/android/ossw/emulator/source/EmulatorConvertedDataSource.java:
--------------------------------------------------------------------------------
1 | package com.althink.android.ossw.emulator.source;
2 |
3 | import com.althink.android.ossw.emulator.renderer.EmulatorExecutionContext;
4 | import com.althink.android.ossw.emulator.source.converter.EmulatorDataConverter;
5 | import com.althink.android.ossw.watchsets.DataSourceType;
6 |
7 | /**
8 | * Created by krzysiek on 29/11/15.
9 | */
10 | public class EmulatorConvertedDataSource implements EmulatorDataSource {
11 |
12 | private EmulatorDataConverter converter;
13 | private EmulatorDataSource dataSource;
14 |
15 | public EmulatorConvertedDataSource(EmulatorDataConverter converter, EmulatorDataSource dataSource) {
16 | this.converter = converter;
17 | this.dataSource = dataSource;
18 | }
19 |
20 | @Override
21 | public Object getData(DataSourceType type, int range, EmulatorExecutionContext ctx) {
22 | return converter.convert(dataSource.getData(type, range, ctx));
23 | }
24 | }
25 |
--------------------------------------------------------------------------------
/app/src/main/java/com/althink/android/ossw/emulator/source/StaticDataSource.java:
--------------------------------------------------------------------------------
1 | package com.althink.android.ossw.emulator.source;
2 |
3 | import com.althink.android.ossw.emulator.renderer.EmulatorExecutionContext;
4 | import com.althink.android.ossw.emulator.source.EmulatorDataSource;
5 | import com.althink.android.ossw.watchsets.DataSourceType;
6 |
7 | /**
8 | * Created by krzysiek on 17/11/15.
9 | */
10 | public class StaticDataSource implements EmulatorDataSource {
11 | private byte[] data;
12 |
13 | public StaticDataSource(byte[] data) {
14 | this.data = data;
15 | }
16 |
17 | @Override
18 | public Object getData(DataSourceType type, int range, EmulatorExecutionContext ctx) {
19 | if (type == DataSourceType.STRING) {
20 | return new String(data);
21 | } else if (type == DataSourceType.NUMBER) {
22 | return new Integer((data[0]&0xFF) << 24 | (data[1]&0xFF) << 16 | (data[2]&0xFF) << 8 | (data[3]&0xFF));
23 | }
24 | return null;
25 | }
26 | }
27 |
--------------------------------------------------------------------------------
/app/src/main/java/com/althink/android/ossw/watchsets/ScreenContext.java:
--------------------------------------------------------------------------------
1 | package com.althink.android.ossw.watchsets;
2 |
3 | import com.althink.android.ossw.watchsets.field.FieldDefinition;
4 |
5 | import java.util.HashMap;
6 | import java.util.Map;
7 |
8 | /**
9 | * Created by krzysiek on 21/11/15.
10 | */
11 | public class ScreenContext {
12 | private Map model = new HashMap<>();
13 | private MemoryAllocator allocator = new MemoryAllocator();
14 |
15 | public Map getModel() {
16 | return model;
17 | }
18 |
19 | public MemoryAllocator getAllocator() {
20 | return allocator;
21 | }
22 |
23 | public static class MemoryAllocator {
24 |
25 | int size = 0;
26 |
27 | public int addBuffer(int size) {
28 | int ptr = this.size;
29 | this.size += size;
30 | return ptr;
31 | }
32 |
33 | public int getSize() {
34 | return size;
35 | }
36 | }
37 | }
38 |
39 |
--------------------------------------------------------------------------------
/app/src/main/java/com/althink/android/ossw/service/ExternalServiceConnection.java:
--------------------------------------------------------------------------------
1 | package com.althink.android.ossw.service;
2 |
3 | import android.content.ComponentName;
4 | import android.content.ServiceConnection;
5 | import android.os.IBinder;
6 | import android.os.Messenger;
7 |
8 | /**
9 | * Created by krzysiek on 14/06/15.
10 | */
11 | public class ExternalServiceConnection {
12 |
13 | private Messenger messanger;
14 | private final ServiceConnection connection = new ServiceConnection() {
15 |
16 | @Override
17 | public void onServiceConnected(ComponentName componentName, IBinder service) {
18 | messanger = new Messenger(service);
19 | }
20 |
21 | @Override
22 | public void onServiceDisconnected(ComponentName componentName) {
23 | messanger = null;
24 | }
25 | };
26 |
27 | public Messenger getMessanger() {
28 | return messanger;
29 | }
30 |
31 | public ServiceConnection getConnection() {
32 | return connection;
33 | }
34 | }
35 |
--------------------------------------------------------------------------------
/app/src/main/res/layout/fragment_watches.xml:
--------------------------------------------------------------------------------
1 |
6 |
7 |
10 |
11 |
18 |
19 |
24 |
25 |
26 |
27 |
--------------------------------------------------------------------------------
/ossw-android.iml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
8 |
9 |
10 |
11 |
12 |
13 |
14 |
15 |
16 |
17 |
18 |
19 |
--------------------------------------------------------------------------------
/app/src/main/res/layout/activity_watch_set_preview.xml:
--------------------------------------------------------------------------------
1 |
2 |
7 |
8 |
13 |
14 |
20 |
25 |
26 |
27 |
--------------------------------------------------------------------------------
/app/src/main/java/com/althink/android/ossw/watchsets/CompiledWatchSet.java:
--------------------------------------------------------------------------------
1 | package com.althink.android.ossw.watchsets;
2 |
3 | import com.althink.android.ossw.service.WatchOperationContext;
4 |
5 | /**
6 | * Created by krzysiek on 13/06/15.
7 | */
8 | public class CompiledWatchSet {
9 |
10 | private int id;
11 | private String name;
12 | private byte[] watchData;
13 | private WatchOperationContext watchContext;
14 |
15 | public String getName() {
16 | return name;
17 | }
18 |
19 | public void setName(String name) {
20 | this.name = name;
21 | }
22 |
23 | public byte[] getWatchData() {
24 | return watchData;
25 | }
26 |
27 | public void setWatchData(byte[] watchData) {
28 | this.watchData = watchData;
29 | }
30 |
31 | public int getId() {
32 | return id;
33 | }
34 |
35 | public void setId(int id) {
36 | this.id = id;
37 | }
38 |
39 | public WatchOperationContext getWatchContext() {
40 | return watchContext;
41 | }
42 |
43 | public void setWatchContext(WatchOperationContext watchContext) {
44 | this.watchContext = watchContext;
45 | }
46 | }
47 |
--------------------------------------------------------------------------------
/app/src/main/res/layout/activity_settings.xml:
--------------------------------------------------------------------------------
1 |
5 |
6 |
11 |
12 |
18 |
23 |
24 |
25 |
29 |
30 |
31 |
32 |
33 |
--------------------------------------------------------------------------------
/app/src/main/java/com/althink/android/ossw/emulator/control/ImageEmulatorControl.java:
--------------------------------------------------------------------------------
1 | package com.althink.android.ossw.emulator.control;
2 |
3 | import com.althink.android.ossw.emulator.renderer.EmulatorExecutionContext;
4 | import com.althink.android.ossw.emulator.renderer.LowLevelRenderer;
5 | import com.althink.android.ossw.emulator.source.EmulatorDataSource;
6 | import com.althink.android.ossw.emulator.source.EmulatorResourceSource;
7 | import com.althink.android.ossw.watchsets.DataSourceType;
8 |
9 | /**
10 | * Created by krzysiek on 14/06/15.
11 | */
12 | public class ImageEmulatorControl extends AbstractEmulatorControl {
13 | private int x;
14 | private int y;
15 | private int width;
16 | private int height;
17 | private EmulatorResourceSource image;
18 |
19 | public ImageEmulatorControl(int x, int y, int width, int height, EmulatorResourceSource image) {
20 | super(null);
21 | this.x = x;
22 | this.y = y;
23 | this.width = width;
24 | this.height = height;
25 | this.image = image;
26 | }
27 |
28 | public void draw(LowLevelRenderer renderer, EmulatorExecutionContext ctx) {
29 | renderer.drawImage(image.getData(), x, y, width, height);
30 | }
31 | }
32 |
--------------------------------------------------------------------------------
/app/src/main/java/com/althink/android/ossw/emulator/actions/EmulatorChooseAction.java:
--------------------------------------------------------------------------------
1 | package com.althink.android.ossw.emulator.actions;
2 |
3 | import com.althink.android.ossw.emulator.renderer.EmulatorExecutionContext;
4 | import com.althink.android.ossw.emulator.source.EmulatorDataSource;
5 | import com.althink.android.ossw.watchsets.DataSourceType;
6 |
7 | import java.util.List;
8 | import java.util.Map;
9 |
10 | /**
11 | * Created by krzysiek on 22/11/15.
12 | */
13 | public class EmulatorChooseAction implements EmulatorAction {
14 |
15 | private EmulatorDataSource dataSource;
16 | private Map