Showing
98 changed files
with
2840 additions
and
0 deletions
.idea/codeStyles/Project.xml
0 → 100644
| 1 | +<component name="ProjectCodeStyleConfiguration"> | ||
| 2 | + <code_scheme name="Project" version="173"> | ||
| 3 | + <codeStyleSettings language="XML"> | ||
| 4 | + <indentOptions> | ||
| 5 | + <option name="CONTINUATION_INDENT_SIZE" value="4" /> | ||
| 6 | + </indentOptions> | ||
| 7 | + <arrangement> | ||
| 8 | + <rules> | ||
| 9 | + <section> | ||
| 10 | + <rule> | ||
| 11 | + <match> | ||
| 12 | + <AND> | ||
| 13 | + <NAME>xmlns:android</NAME> | ||
| 14 | + <XML_ATTRIBUTE /> | ||
| 15 | + <XML_NAMESPACE>^$</XML_NAMESPACE> | ||
| 16 | + </AND> | ||
| 17 | + </match> | ||
| 18 | + </rule> | ||
| 19 | + </section> | ||
| 20 | + <section> | ||
| 21 | + <rule> | ||
| 22 | + <match> | ||
| 23 | + <AND> | ||
| 24 | + <NAME>xmlns:.*</NAME> | ||
| 25 | + <XML_ATTRIBUTE /> | ||
| 26 | + <XML_NAMESPACE>^$</XML_NAMESPACE> | ||
| 27 | + </AND> | ||
| 28 | + </match> | ||
| 29 | + <order>BY_NAME</order> | ||
| 30 | + </rule> | ||
| 31 | + </section> | ||
| 32 | + <section> | ||
| 33 | + <rule> | ||
| 34 | + <match> | ||
| 35 | + <AND> | ||
| 36 | + <NAME>.*:id</NAME> | ||
| 37 | + <XML_ATTRIBUTE /> | ||
| 38 | + <XML_NAMESPACE>http://schemas.android.com/apk/res/android</XML_NAMESPACE> | ||
| 39 | + </AND> | ||
| 40 | + </match> | ||
| 41 | + </rule> | ||
| 42 | + </section> | ||
| 43 | + <section> | ||
| 44 | + <rule> | ||
| 45 | + <match> | ||
| 46 | + <AND> | ||
| 47 | + <NAME>.*:name</NAME> | ||
| 48 | + <XML_ATTRIBUTE /> | ||
| 49 | + <XML_NAMESPACE>http://schemas.android.com/apk/res/android</XML_NAMESPACE> | ||
| 50 | + </AND> | ||
| 51 | + </match> | ||
| 52 | + </rule> | ||
| 53 | + </section> | ||
| 54 | + <section> | ||
| 55 | + <rule> | ||
| 56 | + <match> | ||
| 57 | + <AND> | ||
| 58 | + <NAME>name</NAME> | ||
| 59 | + <XML_ATTRIBUTE /> | ||
| 60 | + <XML_NAMESPACE>^$</XML_NAMESPACE> | ||
| 61 | + </AND> | ||
| 62 | + </match> | ||
| 63 | + </rule> | ||
| 64 | + </section> | ||
| 65 | + <section> | ||
| 66 | + <rule> | ||
| 67 | + <match> | ||
| 68 | + <AND> | ||
| 69 | + <NAME>style</NAME> | ||
| 70 | + <XML_ATTRIBUTE /> | ||
| 71 | + <XML_NAMESPACE>^$</XML_NAMESPACE> | ||
| 72 | + </AND> | ||
| 73 | + </match> | ||
| 74 | + </rule> | ||
| 75 | + </section> | ||
| 76 | + <section> | ||
| 77 | + <rule> | ||
| 78 | + <match> | ||
| 79 | + <AND> | ||
| 80 | + <NAME>.*</NAME> | ||
| 81 | + <XML_ATTRIBUTE /> | ||
| 82 | + <XML_NAMESPACE>^$</XML_NAMESPACE> | ||
| 83 | + </AND> | ||
| 84 | + </match> | ||
| 85 | + <order>BY_NAME</order> | ||
| 86 | + </rule> | ||
| 87 | + </section> | ||
| 88 | + <section> | ||
| 89 | + <rule> | ||
| 90 | + <match> | ||
| 91 | + <AND> | ||
| 92 | + <NAME>.*</NAME> | ||
| 93 | + <XML_ATTRIBUTE /> | ||
| 94 | + <XML_NAMESPACE>http://schemas.android.com/apk/res/android</XML_NAMESPACE> | ||
| 95 | + </AND> | ||
| 96 | + </match> | ||
| 97 | + <order>ANDROID_ATTRIBUTE_ORDER</order> | ||
| 98 | + </rule> | ||
| 99 | + </section> | ||
| 100 | + <section> | ||
| 101 | + <rule> | ||
| 102 | + <match> | ||
| 103 | + <AND> | ||
| 104 | + <NAME>.*</NAME> | ||
| 105 | + <XML_ATTRIBUTE /> | ||
| 106 | + <XML_NAMESPACE>.*</XML_NAMESPACE> | ||
| 107 | + </AND> | ||
| 108 | + </match> | ||
| 109 | + <order>BY_NAME</order> | ||
| 110 | + </rule> | ||
| 111 | + </section> | ||
| 112 | + </rules> | ||
| 113 | + </arrangement> | ||
| 114 | + </codeStyleSettings> | ||
| 115 | + </code_scheme> | ||
| 116 | +</component> |
.idea/libraries/Dart_SDK.xml
0 → 100644
| 1 | +<component name="libraryTable"> | ||
| 2 | + <library name="Dart SDK"> | ||
| 3 | + <CLASSES> | ||
| 4 | + <root url="file://G:/flutter/bin/cache/dart-sdk/lib/async" /> | ||
| 5 | + <root url="file://G:/flutter/bin/cache/dart-sdk/lib/collection" /> | ||
| 6 | + <root url="file://G:/flutter/bin/cache/dart-sdk/lib/convert" /> | ||
| 7 | + <root url="file://G:/flutter/bin/cache/dart-sdk/lib/core" /> | ||
| 8 | + <root url="file://G:/flutter/bin/cache/dart-sdk/lib/developer" /> | ||
| 9 | + <root url="file://G:/flutter/bin/cache/dart-sdk/lib/html" /> | ||
| 10 | + <root url="file://G:/flutter/bin/cache/dart-sdk/lib/io" /> | ||
| 11 | + <root url="file://G:/flutter/bin/cache/dart-sdk/lib/isolate" /> | ||
| 12 | + <root url="file://G:/flutter/bin/cache/dart-sdk/lib/math" /> | ||
| 13 | + <root url="file://G:/flutter/bin/cache/dart-sdk/lib/mirrors" /> | ||
| 14 | + <root url="file://G:/flutter/bin/cache/dart-sdk/lib/typed_data" /> | ||
| 15 | + </CLASSES> | ||
| 16 | + <JAVADOC /> | ||
| 17 | + <SOURCES /> | ||
| 18 | + </library> | ||
| 19 | +</component> |
.idea/libraries/Flutter_Plugins.xml
0 → 100644
.idea/libraries/Flutter_for_Android.xml
0 → 100644
.idea/misc.xml
0 → 100644
.idea/modules.xml
0 → 100644
| 1 | +<?xml version="1.0" encoding="UTF-8"?> | ||
| 2 | +<project version="4"> | ||
| 3 | + <component name="ProjectModuleManager"> | ||
| 4 | + <modules> | ||
| 5 | + <module fileurl="file://$PROJECT_DIR$/wakelock.iml" filepath="$PROJECT_DIR$/wakelock.iml" /> | ||
| 6 | + <module fileurl="file://$PROJECT_DIR$/android/wakelock_android.iml" filepath="$PROJECT_DIR$/android/wakelock_android.iml" /> | ||
| 7 | + <module fileurl="file://$PROJECT_DIR$/example/android/wakelock_example_android.iml" filepath="$PROJECT_DIR$/example/android/wakelock_example_android.iml" /> | ||
| 8 | + </modules> | ||
| 9 | + </component> | ||
| 10 | +</project> |
| 1 | +<component name="ProjectRunConfigurationManager"> | ||
| 2 | + <configuration default="false" name="example/lib/main.dart" type="FlutterRunConfigurationType" factoryName="Flutter" singleton="false"> | ||
| 3 | + <option name="filePath" value="$PROJECT_DIR$/example/lib/main.dart" /> | ||
| 4 | + <method v="2" /> | ||
| 5 | + </configuration> | ||
| 6 | +</component> |
.idea/vcs.xml
0 → 100644
.idea/workspace.xml
0 → 100644
| 1 | +<?xml version="1.0" encoding="UTF-8"?> | ||
| 2 | +<project version="4"> | ||
| 3 | + <component name="ChangeListManager"> | ||
| 4 | + <list default="true" id="e35f5043-5075-4a5a-82bc-38cb15e0cba3" name="Default Changelist" comment="" /> | ||
| 5 | + <ignored path="$PROJECT_DIR$/.dart_tool/" /> | ||
| 6 | + <ignored path="$PROJECT_DIR$/.idea/" /> | ||
| 7 | + <ignored path="$PROJECT_DIR$/.pub/" /> | ||
| 8 | + <ignored path="$PROJECT_DIR$/build/" /> | ||
| 9 | + <ignored path="$PROJECT_DIR$/example/.pub/" /> | ||
| 10 | + <ignored path="$PROJECT_DIR$/example/build/" /> | ||
| 11 | + <option name="EXCLUDED_CONVERTED_TO_IGNORED" value="true" /> | ||
| 12 | + <option name="SHOW_DIALOG" value="false" /> | ||
| 13 | + <option name="HIGHLIGHT_CONFLICTS" value="true" /> | ||
| 14 | + <option name="HIGHLIGHT_NON_ACTIVE_CHANGELIST" value="false" /> | ||
| 15 | + <option name="LAST_RESOLUTION" value="IGNORE" /> | ||
| 16 | + </component> | ||
| 17 | + <component name="DefaultGradleProjectSettings"> | ||
| 18 | + <option name="testRunner" value="GRADLE" /> | ||
| 19 | + <option name="delegatedBuild" value="true" /> | ||
| 20 | + </component> | ||
| 21 | + <component name="ExecutionTargetManager" SELECTED_TARGET="P" /> | ||
| 22 | + <component name="FileEditorManager"> | ||
| 23 | + <leaf SIDE_TABS_SIZE_LIMIT_KEY="300"> | ||
| 24 | + <file pinned="false" current-in-tab="false"> | ||
| 25 | + <entry file="file://$PROJECT_DIR$/lib/wakelock.dart"> | ||
| 26 | + <provider selected="true" editor-type-id="text-editor"> | ||
| 27 | + <state relative-caret-position="512"> | ||
| 28 | + <caret line="34" column="43" selection-start-line="34" selection-start-column="43" selection-end-line="34" selection-end-column="43" /> | ||
| 29 | + <folding> | ||
| 30 | + <element signature="e#63#147#0" expanded="true" /> | ||
| 31 | + <element signature="e#742#835#0" expanded="true" /> | ||
| 32 | + <element signature="e#1010#1104#0" expanded="true" /> | ||
| 33 | + <element signature="e#1283#1364#0" expanded="true" /> | ||
| 34 | + <element signature="e#989#1096#0" expanded="true" /> | ||
| 35 | + </folding> | ||
| 36 | + </state> | ||
| 37 | + </provider> | ||
| 38 | + </entry> | ||
| 39 | + </file> | ||
| 40 | + <file pinned="false" current-in-tab="false"> | ||
| 41 | + <entry file="file://$PROJECT_DIR$/ios/Classes/WakelockPlugin.h"> | ||
| 42 | + <provider selected="true" editor-type-id="text-editor" /> | ||
| 43 | + </entry> | ||
| 44 | + </file> | ||
| 45 | + <file pinned="false" current-in-tab="false"> | ||
| 46 | + <entry file="file://$PROJECT_DIR$/ios/Classes/WakelockPlugin.m"> | ||
| 47 | + <provider selected="true" editor-type-id="text-editor" /> | ||
| 48 | + </entry> | ||
| 49 | + </file> | ||
| 50 | + <file pinned="false" current-in-tab="false"> | ||
| 51 | + <entry file="file://$PROJECT_DIR$/CHANGELOG.md"> | ||
| 52 | + <provider selected="true" editor-type-id="text-editor"> | ||
| 53 | + <state relative-caret-position="48"> | ||
| 54 | + <caret line="3" column="34" selection-start-line="3" selection-start-column="34" selection-end-line="3" selection-end-column="34" /> | ||
| 55 | + </state> | ||
| 56 | + </provider> | ||
| 57 | + </entry> | ||
| 58 | + </file> | ||
| 59 | + <file pinned="false" current-in-tab="false"> | ||
| 60 | + <entry file="file://$PROJECT_DIR$/README.md"> | ||
| 61 | + <provider selected="true" editor-type-id="text-editor"> | ||
| 62 | + <state relative-caret-position="335"> | ||
| 63 | + <caret line="26" column="66" selection-start-line="26" selection-start-column="66" selection-end-line="26" selection-end-column="66" /> | ||
| 64 | + </state> | ||
| 65 | + </provider> | ||
| 66 | + </entry> | ||
| 67 | + </file> | ||
| 68 | + <file pinned="false" current-in-tab="false"> | ||
| 69 | + <entry file="file://$PROJECT_DIR$/pubspec.yaml"> | ||
| 70 | + <provider selected="true" editor-type-id="text-editor"> | ||
| 71 | + <state relative-caret-position="16"> | ||
| 72 | + <caret line="1" column="183" lean-forward="true" selection-start-line="1" selection-start-column="13" selection-end-line="1" selection-end-column="183" /> | ||
| 73 | + </state> | ||
| 74 | + </provider> | ||
| 75 | + </entry> | ||
| 76 | + </file> | ||
| 77 | + <file pinned="false" current-in-tab="true"> | ||
| 78 | + <entry file="file://$PROJECT_DIR$/example/README.md"> | ||
| 79 | + <provider selected="true" editor-type-id="text-editor" /> | ||
| 80 | + </entry> | ||
| 81 | + </file> | ||
| 82 | + <file pinned="false" current-in-tab="false"> | ||
| 83 | + <entry file="file://$PROJECT_DIR$/example/lib/main.dart"> | ||
| 84 | + <provider selected="true" editor-type-id="text-editor"> | ||
| 85 | + <state> | ||
| 86 | + <folding> | ||
| 87 | + <element signature="e#0#39#0" expanded="true" /> | ||
| 88 | + </folding> | ||
| 89 | + </state> | ||
| 90 | + </provider> | ||
| 91 | + </entry> | ||
| 92 | + </file> | ||
| 93 | + </leaf> | ||
| 94 | + </component> | ||
| 95 | + <component name="FindInProjectRecents"> | ||
| 96 | + <findStrings> | ||
| 97 | + <find>isEqualToString</find> | ||
| 98 | + <find>isEqualToString:call.method</find> | ||
| 99 | + <find>boolean</find> | ||
| 100 | + </findStrings> | ||
| 101 | + </component> | ||
| 102 | + <component name="Git.Settings"> | ||
| 103 | + <option name="RECENT_GIT_ROOT_PATH" value="$PROJECT_DIR$" /> | ||
| 104 | + </component> | ||
| 105 | + <component name="IdeDocumentHistory"> | ||
| 106 | + <option name="CHANGED_PATHS"> | ||
| 107 | + <list> | ||
| 108 | + <option value="$PROJECT_DIR$/ios/Classes/WakelockPlugin.m" /> | ||
| 109 | + <option value="$PROJECT_DIR$/CHANGELOG.md" /> | ||
| 110 | + <option value="$PROJECT_DIR$/LICENSE" /> | ||
| 111 | + <option value="$PROJECT_DIR$/lib/wakelock.dart" /> | ||
| 112 | + <option value="$PROJECT_DIR$/pubspec.yaml" /> | ||
| 113 | + <option value="$PROJECT_DIR$/README.md" /> | ||
| 114 | + </list> | ||
| 115 | + </option> | ||
| 116 | + </component> | ||
| 117 | + <component name="ProjectFrameBounds" extendedState="6"> | ||
| 118 | + <option name="x" value="-8" /> | ||
| 119 | + <option name="y" value="-8" /> | ||
| 120 | + <option name="width" value="1936" /> | ||
| 121 | + <option name="height" value="1096" /> | ||
| 122 | + </component> | ||
| 123 | + <component name="ProjectLevelVcsManager" settingsEditedManually="true" /> | ||
| 124 | + <component name="ProjectView"> | ||
| 125 | + <navigator currentView="ProjectPane" proportions="" version="1"> | ||
| 126 | + <foldersAlwaysOnTop value="true" /> | ||
| 127 | + </navigator> | ||
| 128 | + <panes> | ||
| 129 | + <pane id="AndroidView" /> | ||
| 130 | + <pane id="ProjectPane"> | ||
| 131 | + <subPane> | ||
| 132 | + <expand> | ||
| 133 | + <path> | ||
| 134 | + <item name="wakelock" type="b2602c69:ProjectViewProjectNode" /> | ||
| 135 | + <item name="wakelock" type="462c0819:PsiDirectoryNode" /> | ||
| 136 | + </path> | ||
| 137 | + <path> | ||
| 138 | + <item name="wakelock" type="b2602c69:ProjectViewProjectNode" /> | ||
| 139 | + <item name="wakelock" type="462c0819:PsiDirectoryNode" /> | ||
| 140 | + <item name="ios" type="462c0819:PsiDirectoryNode" /> | ||
| 141 | + </path> | ||
| 142 | + <path> | ||
| 143 | + <item name="wakelock" type="b2602c69:ProjectViewProjectNode" /> | ||
| 144 | + <item name="wakelock" type="462c0819:PsiDirectoryNode" /> | ||
| 145 | + <item name="ios" type="462c0819:PsiDirectoryNode" /> | ||
| 146 | + <item name="Classes" type="462c0819:PsiDirectoryNode" /> | ||
| 147 | + </path> | ||
| 148 | + </expand> | ||
| 149 | + <select /> | ||
| 150 | + </subPane> | ||
| 151 | + </pane> | ||
| 152 | + <pane id="PackagesPane" /> | ||
| 153 | + <pane id="Scope" /> | ||
| 154 | + </panes> | ||
| 155 | + </component> | ||
| 156 | + <component name="PropertiesComponent"> | ||
| 157 | + <property name="SHARE_PROJECT_CONFIGURATION_FILES" value="true" /> | ||
| 158 | + <property name="dart.analysis.tool.window.force.activate" value="false" /> | ||
| 159 | + <property name="io.flutter.reload.alreadyRun" value="true" /> | ||
| 160 | + <property name="last_opened_file_path" value="$PROJECT_DIR$/android" /> | ||
| 161 | + <property name="show.migrate.to.gradle.popup" value="false" /> | ||
| 162 | + </component> | ||
| 163 | + <component name="RunDashboard"> | ||
| 164 | + <option name="ruleStates"> | ||
| 165 | + <list> | ||
| 166 | + <RuleState> | ||
| 167 | + <option name="name" value="ConfigurationTypeDashboardGroupingRule" /> | ||
| 168 | + </RuleState> | ||
| 169 | + <RuleState> | ||
| 170 | + <option name="name" value="StatusDashboardGroupingRule" /> | ||
| 171 | + </RuleState> | ||
| 172 | + </list> | ||
| 173 | + </option> | ||
| 174 | + </component> | ||
| 175 | + <component name="SvnConfiguration"> | ||
| 176 | + <configuration /> | ||
| 177 | + </component> | ||
| 178 | + <component name="TaskManager"> | ||
| 179 | + <task active="true" id="Default" summary="Default task"> | ||
| 180 | + <changelist id="e35f5043-5075-4a5a-82bc-38cb15e0cba3" name="Default Changelist" comment="" /> | ||
| 181 | + <created>1562454080446</created> | ||
| 182 | + <option name="number" value="Default" /> | ||
| 183 | + <option name="presentableId" value="Default" /> | ||
| 184 | + <updated>1562454080446</updated> | ||
| 185 | + </task> | ||
| 186 | + <servers /> | ||
| 187 | + </component> | ||
| 188 | + <component name="ToolWindowManager"> | ||
| 189 | + <frame x="-8" y="-8" width="1936" height="1096" extended-state="6" /> | ||
| 190 | + <layout> | ||
| 191 | + <window_info id="Capture Tool" /> | ||
| 192 | + <window_info id="Captures" side_tool="true" /> | ||
| 193 | + <window_info id="Structure" side_tool="true" /> | ||
| 194 | + <window_info id="Favorites" side_tool="true" /> | ||
| 195 | + <window_info id="Image Layers" /> | ||
| 196 | + <window_info id="Designer" /> | ||
| 197 | + <window_info id="Build Variants" side_tool="true" /> | ||
| 198 | + <window_info id="Resources Explorer" /> | ||
| 199 | + <window_info active="true" content_ui="combo" id="Project" order="0" visible="true" weight="0.25" /> | ||
| 200 | + <window_info anchor="bottom" id="Run" visible="true" weight="0.32917964" /> | ||
| 201 | + <window_info anchor="bottom" id="Dart Analysis" weight="0.32917964" /> | ||
| 202 | + <window_info anchor="bottom" id="TODO" /> | ||
| 203 | + <window_info anchor="bottom" id="Logcat" /> | ||
| 204 | + <window_info anchor="bottom" id="Debug" /> | ||
| 205 | + <window_info anchor="bottom" id="Terminal" /> | ||
| 206 | + <window_info anchor="bottom" id="Event Log" side_tool="true" /> | ||
| 207 | + <window_info anchor="bottom" id="Flutter Performance" side_tool="true" /> | ||
| 208 | + <window_info anchor="bottom" id="Version Control" /> | ||
| 209 | + <window_info anchor="bottom" id="Android Profiler" show_stripe_button="false" /> | ||
| 210 | + <window_info anchor="right" id="Device File Explorer" side_tool="true" /> | ||
| 211 | + <window_info anchor="right" id="Capture Analysis" /> | ||
| 212 | + <window_info anchor="right" id="Theme Preview" /> | ||
| 213 | + <window_info anchor="right" id="Flutter Inspector" /> | ||
| 214 | + <window_info anchor="right" id="Flutter Outline" /> | ||
| 215 | + <window_info anchor="right" id="Palette	" /> | ||
| 216 | + </layout> | ||
| 217 | + </component> | ||
| 218 | + <component name="editorHistoryManager"> | ||
| 219 | + <entry file="file://$PROJECT_DIR$/test/wakelock_test.dart"> | ||
| 220 | + <provider selected="true" editor-type-id="text-editor"> | ||
| 221 | + <state relative-caret-position="256"> | ||
| 222 | + <caret line="18" column="49" lean-forward="true" selection-start-line="18" selection-start-column="49" selection-end-line="18" selection-end-column="49" /> | ||
| 223 | + </state> | ||
| 224 | + </provider> | ||
| 225 | + </entry> | ||
| 226 | + <entry file="file://$PROJECT_DIR$/CHANGELOG.md"> | ||
| 227 | + <provider selected="true" editor-type-id="text-editor"> | ||
| 228 | + <state relative-caret-position="48"> | ||
| 229 | + <caret line="3" column="34" selection-start-line="3" selection-start-column="34" selection-end-line="3" selection-end-column="34" /> | ||
| 230 | + </state> | ||
| 231 | + </provider> | ||
| 232 | + </entry> | ||
| 233 | + <entry file="file://$PROJECT_DIR$/LICENSE"> | ||
| 234 | + <provider selected="true" editor-type-id="text-editor" /> | ||
| 235 | + </entry> | ||
| 236 | + <entry file="file://$PROJECT_DIR$/ios/Classes/WakelockPlugin.h"> | ||
| 237 | + <provider selected="true" editor-type-id="text-editor" /> | ||
| 238 | + </entry> | ||
| 239 | + <entry file="file://$PROJECT_DIR$/lib/wakelock.dart"> | ||
| 240 | + <provider selected="true" editor-type-id="text-editor"> | ||
| 241 | + <state relative-caret-position="512"> | ||
| 242 | + <caret line="34" column="43" selection-start-line="34" selection-start-column="43" selection-end-line="34" selection-end-column="43" /> | ||
| 243 | + <folding> | ||
| 244 | + <element signature="e#63#147#0" expanded="true" /> | ||
| 245 | + <element signature="e#742#835#0" expanded="true" /> | ||
| 246 | + <element signature="e#1010#1104#0" expanded="true" /> | ||
| 247 | + <element signature="e#1283#1364#0" expanded="true" /> | ||
| 248 | + <element signature="e#989#1096#0" expanded="true" /> | ||
| 249 | + </folding> | ||
| 250 | + </state> | ||
| 251 | + </provider> | ||
| 252 | + </entry> | ||
| 253 | + <entry file="file://$PROJECT_DIR$/example/lib/main.dart"> | ||
| 254 | + <provider selected="true" editor-type-id="text-editor"> | ||
| 255 | + <state> | ||
| 256 | + <folding> | ||
| 257 | + <element signature="e#0#39#0" expanded="true" /> | ||
| 258 | + </folding> | ||
| 259 | + </state> | ||
| 260 | + </provider> | ||
| 261 | + </entry> | ||
| 262 | + <entry file="file://$PROJECT_DIR$/README.md"> | ||
| 263 | + <provider selected="true" editor-type-id="text-editor"> | ||
| 264 | + <state relative-caret-position="335"> | ||
| 265 | + <caret line="26" column="66" selection-start-line="26" selection-start-column="66" selection-end-line="26" selection-end-column="66" /> | ||
| 266 | + </state> | ||
| 267 | + </provider> | ||
| 268 | + </entry> | ||
| 269 | + <entry file="file://$PROJECT_DIR$/ios/Classes/WakelockPlugin.m"> | ||
| 270 | + <provider selected="true" editor-type-id="text-editor" /> | ||
| 271 | + </entry> | ||
| 272 | + <entry file="file://$PROJECT_DIR$/pubspec.yaml"> | ||
| 273 | + <provider selected="true" editor-type-id="text-editor"> | ||
| 274 | + <state relative-caret-position="16"> | ||
| 275 | + <caret line="1" column="183" lean-forward="true" selection-start-line="1" selection-start-column="13" selection-end-line="1" selection-end-column="183" /> | ||
| 276 | + </state> | ||
| 277 | + </provider> | ||
| 278 | + </entry> | ||
| 279 | + <entry file="file://$PROJECT_DIR$/example/README.md"> | ||
| 280 | + <provider selected="true" editor-type-id="text-editor" /> | ||
| 281 | + </entry> | ||
| 282 | + </component> | ||
| 283 | +</project> |
.metadata
0 → 100644
| 1 | +# This file tracks properties of this Flutter project. | ||
| 2 | +# Used by Flutter tool to assess capabilities and perform upgrades etc. | ||
| 3 | +# | ||
| 4 | +# This file should be version controlled and should not be manually edited. | ||
| 5 | + | ||
| 6 | +version: | ||
| 7 | + revision: 3bf91b543678d6dc677a9c3f1f2ea32a769ddbcb | ||
| 8 | + channel: master | ||
| 9 | + | ||
| 10 | +project_type: plugin |
CHANGELOG.md
0 → 100644
LICENSE
0 → 100644
| 1 | +BSD 2-Clause License | ||
| 2 | + | ||
| 3 | +Copyright (c) 2019, creativecreatorormaybenot | ||
| 4 | +All rights reserved. | ||
| 5 | + | ||
| 6 | +Redistribution and use in source and binary forms, with or without | ||
| 7 | +modification, are permitted provided that the following conditions are met: | ||
| 8 | + | ||
| 9 | +1. Redistributions of source code must retain the above copyright notice, this | ||
| 10 | + list of conditions and the following disclaimer. | ||
| 11 | + | ||
| 12 | +2. Redistributions in binary form must reproduce the above copyright notice, | ||
| 13 | + this list of conditions and the following disclaimer in the documentation | ||
| 14 | + and/or other materials provided with the distribution. | ||
| 15 | + | ||
| 16 | +THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" | ||
| 17 | +AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE | ||
| 18 | +IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE | ||
| 19 | +DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE | ||
| 20 | +FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL | ||
| 21 | +DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR | ||
| 22 | +SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER | ||
| 23 | +CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, | ||
| 24 | +OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE | ||
| 25 | +OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. |
README.md
0 → 100644
| 1 | +# Wakelock | ||
| 2 | + | ||
| 3 | +This plugin allows you to enable and toggle the Android and iOS screen wakelock, which prevents the screen from turning off automatically. | ||
| 4 | + | ||
| 5 | +## Getting Started | ||
| 6 | + | ||
| 7 | +The usage of this plugin is very straight forward. | ||
| 8 | +If you want to enable the wakelock, you can simply call `Wakelock.enableWakelock` and to disable it, you can use `Wakelock.disableWakelock`: | ||
| 9 | + | ||
| 10 | +```dart | ||
| 11 | +import 'package:wakelock/wakelock.dart'; | ||
| 12 | +// ... | ||
| 13 | + | ||
| 14 | +// The following line will enable the Android and iOS wakelock. | ||
| 15 | +Wakelock.enableWakelock(); | ||
| 16 | + | ||
| 17 | +// The next line disables the wakelock again. | ||
| 18 | +Wakelock.disableWakelock(); | ||
| 19 | +``` | ||
| 20 | + | ||
| 21 | +For more advanced usage, you can pass a `bool` to `Wakelock.toggleWakelock` to enable or disable the wakelock and also retrieve the current wakelock status using `Wakelock.isWakelockEnabled`: | ||
| 22 | + | ||
| 23 | +```dart | ||
| 24 | +import 'package:wakelock/wakelock.dart'; | ||
| 25 | +// ... | ||
| 26 | + | ||
| 27 | +// The following lines of code toggle the wakelock based on a bool value. | ||
| 28 | +bool enableWakelock = true; | ||
| 29 | +Wakelock.toggleWakelock(enableWakelock); // This statement enables the wakelock. | ||
| 30 | + | ||
| 31 | +enableWakelock = false; | ||
| 32 | +Wakelock.toggleWakelock(enableWakelock); // This statement disables the wakelock. | ||
| 33 | + | ||
| 34 | +// If you want to retrieve the current wakelock status, you will have to be in an async scope to await the Future returned by isWakelockEnabled. | ||
| 35 | +bool isWakelockEnabled = await Wakelock.isWakelockEnabled; | ||
| 36 | +``` | ||
| 37 | + | ||
| 38 | +If you want to wait for the wakelock toggle on Android or iOS to complete (which takes an insignificant amount of time), you can also await either of `Wakelock.enableWakelock`, `Wakelock.disableWakelock`, and `Wakelock.toggleWakelock`. |
android/.gitignore
0 → 100644
android/.idea/.name
0 → 100644
| 1 | +wakelock |
No preview for this file type
android/.idea/caches/gradle_models.ser
0 → 100644
No preview for this file type
android/.idea/codeStyles/Project.xml
0 → 100644
| 1 | +<component name="ProjectCodeStyleConfiguration"> | ||
| 2 | + <code_scheme name="Project" version="173"> | ||
| 3 | + <codeStyleSettings language="XML"> | ||
| 4 | + <indentOptions> | ||
| 5 | + <option name="CONTINUATION_INDENT_SIZE" value="4" /> | ||
| 6 | + </indentOptions> | ||
| 7 | + <arrangement> | ||
| 8 | + <rules> | ||
| 9 | + <section> | ||
| 10 | + <rule> | ||
| 11 | + <match> | ||
| 12 | + <AND> | ||
| 13 | + <NAME>xmlns:android</NAME> | ||
| 14 | + <XML_ATTRIBUTE /> | ||
| 15 | + <XML_NAMESPACE>^$</XML_NAMESPACE> | ||
| 16 | + </AND> | ||
| 17 | + </match> | ||
| 18 | + </rule> | ||
| 19 | + </section> | ||
| 20 | + <section> | ||
| 21 | + <rule> | ||
| 22 | + <match> | ||
| 23 | + <AND> | ||
| 24 | + <NAME>xmlns:.*</NAME> | ||
| 25 | + <XML_ATTRIBUTE /> | ||
| 26 | + <XML_NAMESPACE>^$</XML_NAMESPACE> | ||
| 27 | + </AND> | ||
| 28 | + </match> | ||
| 29 | + <order>BY_NAME</order> | ||
| 30 | + </rule> | ||
| 31 | + </section> | ||
| 32 | + <section> | ||
| 33 | + <rule> | ||
| 34 | + <match> | ||
| 35 | + <AND> | ||
| 36 | + <NAME>.*:id</NAME> | ||
| 37 | + <XML_ATTRIBUTE /> | ||
| 38 | + <XML_NAMESPACE>http://schemas.android.com/apk/res/android</XML_NAMESPACE> | ||
| 39 | + </AND> | ||
| 40 | + </match> | ||
| 41 | + </rule> | ||
| 42 | + </section> | ||
| 43 | + <section> | ||
| 44 | + <rule> | ||
| 45 | + <match> | ||
| 46 | + <AND> | ||
| 47 | + <NAME>.*:name</NAME> | ||
| 48 | + <XML_ATTRIBUTE /> | ||
| 49 | + <XML_NAMESPACE>http://schemas.android.com/apk/res/android</XML_NAMESPACE> | ||
| 50 | + </AND> | ||
| 51 | + </match> | ||
| 52 | + </rule> | ||
| 53 | + </section> | ||
| 54 | + <section> | ||
| 55 | + <rule> | ||
| 56 | + <match> | ||
| 57 | + <AND> | ||
| 58 | + <NAME>name</NAME> | ||
| 59 | + <XML_ATTRIBUTE /> | ||
| 60 | + <XML_NAMESPACE>^$</XML_NAMESPACE> | ||
| 61 | + </AND> | ||
| 62 | + </match> | ||
| 63 | + </rule> | ||
| 64 | + </section> | ||
| 65 | + <section> | ||
| 66 | + <rule> | ||
| 67 | + <match> | ||
| 68 | + <AND> | ||
| 69 | + <NAME>style</NAME> | ||
| 70 | + <XML_ATTRIBUTE /> | ||
| 71 | + <XML_NAMESPACE>^$</XML_NAMESPACE> | ||
| 72 | + </AND> | ||
| 73 | + </match> | ||
| 74 | + </rule> | ||
| 75 | + </section> | ||
| 76 | + <section> | ||
| 77 | + <rule> | ||
| 78 | + <match> | ||
| 79 | + <AND> | ||
| 80 | + <NAME>.*</NAME> | ||
| 81 | + <XML_ATTRIBUTE /> | ||
| 82 | + <XML_NAMESPACE>^$</XML_NAMESPACE> | ||
| 83 | + </AND> | ||
| 84 | + </match> | ||
| 85 | + <order>BY_NAME</order> | ||
| 86 | + </rule> | ||
| 87 | + </section> | ||
| 88 | + <section> | ||
| 89 | + <rule> | ||
| 90 | + <match> | ||
| 91 | + <AND> | ||
| 92 | + <NAME>.*</NAME> | ||
| 93 | + <XML_ATTRIBUTE /> | ||
| 94 | + <XML_NAMESPACE>http://schemas.android.com/apk/res/android</XML_NAMESPACE> | ||
| 95 | + </AND> | ||
| 96 | + </match> | ||
| 97 | + <order>ANDROID_ATTRIBUTE_ORDER</order> | ||
| 98 | + </rule> | ||
| 99 | + </section> | ||
| 100 | + <section> | ||
| 101 | + <rule> | ||
| 102 | + <match> | ||
| 103 | + <AND> | ||
| 104 | + <NAME>.*</NAME> | ||
| 105 | + <XML_ATTRIBUTE /> | ||
| 106 | + <XML_NAMESPACE>.*</XML_NAMESPACE> | ||
| 107 | + </AND> | ||
| 108 | + </match> | ||
| 109 | + <order>BY_NAME</order> | ||
| 110 | + </rule> | ||
| 111 | + </section> | ||
| 112 | + </rules> | ||
| 113 | + </arrangement> | ||
| 114 | + </codeStyleSettings> | ||
| 115 | + </code_scheme> | ||
| 116 | +</component> |
android/.idea/gradle.xml
0 → 100644
| 1 | +<?xml version="1.0" encoding="UTF-8"?> | ||
| 2 | +<project version="4"> | ||
| 3 | + <component name="GradleSettings"> | ||
| 4 | + <option name="linkedExternalProjectsSettings"> | ||
| 5 | + <GradleProjectSettings> | ||
| 6 | + <compositeConfiguration> | ||
| 7 | + <compositeBuild compositeDefinitionSource="SCRIPT" /> | ||
| 8 | + </compositeConfiguration> | ||
| 9 | + <option name="distributionType" value="DEFAULT_WRAPPED" /> | ||
| 10 | + <option name="externalProjectPath" value="$PROJECT_DIR$" /> | ||
| 11 | + <option name="resolveModulePerSourceSet" value="false" /> | ||
| 12 | + <option name="testRunner" value="PLATFORM" /> | ||
| 13 | + </GradleProjectSettings> | ||
| 14 | + </option> | ||
| 15 | + </component> | ||
| 16 | +</project> |
android/.idea/misc.xml
0 → 100644
android/.idea/modules.xml
0 → 100644
android/.idea/runConfigurations.xml
0 → 100644
| 1 | +<?xml version="1.0" encoding="UTF-8"?> | ||
| 2 | +<project version="4"> | ||
| 3 | + <component name="RunConfigurationProducerService"> | ||
| 4 | + <option name="ignoredProducers"> | ||
| 5 | + <set> | ||
| 6 | + <option value="org.jetbrains.plugins.gradle.execution.test.runner.AllInPackageGradleConfigurationProducer" /> | ||
| 7 | + <option value="org.jetbrains.plugins.gradle.execution.test.runner.TestClassGradleConfigurationProducer" /> | ||
| 8 | + <option value="org.jetbrains.plugins.gradle.execution.test.runner.TestMethodGradleConfigurationProducer" /> | ||
| 9 | + </set> | ||
| 10 | + </option> | ||
| 11 | + </component> | ||
| 12 | +</project> |
android/.idea/vcs.xml
0 → 100644
android/build.gradle
0 → 100644
| 1 | +group 'wakelock.wakelock' | ||
| 2 | +version '1.0-SNAPSHOT' | ||
| 3 | + | ||
| 4 | +buildscript { | ||
| 5 | + repositories { | ||
| 6 | + google() | ||
| 7 | + jcenter() | ||
| 8 | + } | ||
| 9 | + | ||
| 10 | + dependencies { | ||
| 11 | + classpath 'com.android.tools.build:gradle:3.2.1' | ||
| 12 | + } | ||
| 13 | +} | ||
| 14 | + | ||
| 15 | +rootProject.allprojects { | ||
| 16 | + repositories { | ||
| 17 | + google() | ||
| 18 | + jcenter() | ||
| 19 | + } | ||
| 20 | +} | ||
| 21 | + | ||
| 22 | +apply plugin: 'com.android.library' | ||
| 23 | + | ||
| 24 | +android { | ||
| 25 | + compileSdkVersion 28 | ||
| 26 | + | ||
| 27 | + defaultConfig { | ||
| 28 | + minSdkVersion 16 | ||
| 29 | + testInstrumentationRunner "android.support.test.runner.AndroidJUnitRunner" | ||
| 30 | + } | ||
| 31 | + lintOptions { | ||
| 32 | + disable 'InvalidPackage' | ||
| 33 | + } | ||
| 34 | +} |
android/gradle.properties
0 → 100644
android/gradle/wrapper/gradle-wrapper.jar
0 → 100644
No preview for this file type
android/gradlew
0 → 100644
| 1 | +#!/usr/bin/env sh | ||
| 2 | + | ||
| 3 | +############################################################################## | ||
| 4 | +## | ||
| 5 | +## Gradle start up script for UN*X | ||
| 6 | +## | ||
| 7 | +############################################################################## | ||
| 8 | + | ||
| 9 | +# Attempt to set APP_HOME | ||
| 10 | +# Resolve links: $0 may be a link | ||
| 11 | +PRG="$0" | ||
| 12 | +# Need this for relative symlinks. | ||
| 13 | +while [ -h "$PRG" ] ; do | ||
| 14 | + ls=`ls -ld "$PRG"` | ||
| 15 | + link=`expr "$ls" : '.*-> \(.*\)$'` | ||
| 16 | + if expr "$link" : '/.*' > /dev/null; then | ||
| 17 | + PRG="$link" | ||
| 18 | + else | ||
| 19 | + PRG=`dirname "$PRG"`"/$link" | ||
| 20 | + fi | ||
| 21 | +done | ||
| 22 | +SAVED="`pwd`" | ||
| 23 | +cd "`dirname \"$PRG\"`/" >/dev/null | ||
| 24 | +APP_HOME="`pwd -P`" | ||
| 25 | +cd "$SAVED" >/dev/null | ||
| 26 | + | ||
| 27 | +APP_NAME="Gradle" | ||
| 28 | +APP_BASE_NAME=`basename "$0"` | ||
| 29 | + | ||
| 30 | +# Add default JVM options here. You can also use JAVA_OPTS and GRADLE_OPTS to pass JVM options to this script. | ||
| 31 | +DEFAULT_JVM_OPTS="" | ||
| 32 | + | ||
| 33 | +# Use the maximum available, or set MAX_FD != -1 to use that value. | ||
| 34 | +MAX_FD="maximum" | ||
| 35 | + | ||
| 36 | +warn () { | ||
| 37 | + echo "$*" | ||
| 38 | +} | ||
| 39 | + | ||
| 40 | +die () { | ||
| 41 | + echo | ||
| 42 | + echo "$*" | ||
| 43 | + echo | ||
| 44 | + exit 1 | ||
| 45 | +} | ||
| 46 | + | ||
| 47 | +# OS specific support (must be 'true' or 'false'). | ||
| 48 | +cygwin=false | ||
| 49 | +msys=false | ||
| 50 | +darwin=false | ||
| 51 | +nonstop=false | ||
| 52 | +case "`uname`" in | ||
| 53 | + CYGWIN* ) | ||
| 54 | + cygwin=true | ||
| 55 | + ;; | ||
| 56 | + Darwin* ) | ||
| 57 | + darwin=true | ||
| 58 | + ;; | ||
| 59 | + MINGW* ) | ||
| 60 | + msys=true | ||
| 61 | + ;; | ||
| 62 | + NONSTOP* ) | ||
| 63 | + nonstop=true | ||
| 64 | + ;; | ||
| 65 | +esac | ||
| 66 | + | ||
| 67 | +CLASSPATH=$APP_HOME/gradle/wrapper/gradle-wrapper.jar | ||
| 68 | + | ||
| 69 | +# Determine the Java command to use to start the JVM. | ||
| 70 | +if [ -n "$JAVA_HOME" ] ; then | ||
| 71 | + if [ -x "$JAVA_HOME/jre/sh/java" ] ; then | ||
| 72 | + # IBM's JDK on AIX uses strange locations for the executables | ||
| 73 | + JAVACMD="$JAVA_HOME/jre/sh/java" | ||
| 74 | + else | ||
| 75 | + JAVACMD="$JAVA_HOME/bin/java" | ||
| 76 | + fi | ||
| 77 | + if [ ! -x "$JAVACMD" ] ; then | ||
| 78 | + die "ERROR: JAVA_HOME is set to an invalid directory: $JAVA_HOME | ||
| 79 | + | ||
| 80 | +Please set the JAVA_HOME variable in your environment to match the | ||
| 81 | +location of your Java installation." | ||
| 82 | + fi | ||
| 83 | +else | ||
| 84 | + JAVACMD="java" | ||
| 85 | + which java >/dev/null 2>&1 || die "ERROR: JAVA_HOME is not set and no 'java' command could be found in your PATH. | ||
| 86 | + | ||
| 87 | +Please set the JAVA_HOME variable in your environment to match the | ||
| 88 | +location of your Java installation." | ||
| 89 | +fi | ||
| 90 | + | ||
| 91 | +# Increase the maximum file descriptors if we can. | ||
| 92 | +if [ "$cygwin" = "false" -a "$darwin" = "false" -a "$nonstop" = "false" ] ; then | ||
| 93 | + MAX_FD_LIMIT=`ulimit -H -n` | ||
| 94 | + if [ $? -eq 0 ] ; then | ||
| 95 | + if [ "$MAX_FD" = "maximum" -o "$MAX_FD" = "max" ] ; then | ||
| 96 | + MAX_FD="$MAX_FD_LIMIT" | ||
| 97 | + fi | ||
| 98 | + ulimit -n $MAX_FD | ||
| 99 | + if [ $? -ne 0 ] ; then | ||
| 100 | + warn "Could not set maximum file descriptor limit: $MAX_FD" | ||
| 101 | + fi | ||
| 102 | + else | ||
| 103 | + warn "Could not query maximum file descriptor limit: $MAX_FD_LIMIT" | ||
| 104 | + fi | ||
| 105 | +fi | ||
| 106 | + | ||
| 107 | +# For Darwin, add options to specify how the application appears in the dock | ||
| 108 | +if $darwin; then | ||
| 109 | + GRADLE_OPTS="$GRADLE_OPTS \"-Xdock:name=$APP_NAME\" \"-Xdock:icon=$APP_HOME/media/gradle.icns\"" | ||
| 110 | +fi | ||
| 111 | + | ||
| 112 | +# For Cygwin, switch paths to Windows format before running java | ||
| 113 | +if $cygwin ; then | ||
| 114 | + APP_HOME=`cygpath --path --mixed "$APP_HOME"` | ||
| 115 | + CLASSPATH=`cygpath --path --mixed "$CLASSPATH"` | ||
| 116 | + JAVACMD=`cygpath --unix "$JAVACMD"` | ||
| 117 | + | ||
| 118 | + # We build the pattern for arguments to be converted via cygpath | ||
| 119 | + ROOTDIRSRAW=`find -L / -maxdepth 1 -mindepth 1 -type d 2>/dev/null` | ||
| 120 | + SEP="" | ||
| 121 | + for dir in $ROOTDIRSRAW ; do | ||
| 122 | + ROOTDIRS="$ROOTDIRS$SEP$dir" | ||
| 123 | + SEP="|" | ||
| 124 | + done | ||
| 125 | + OURCYGPATTERN="(^($ROOTDIRS))" | ||
| 126 | + # Add a user-defined pattern to the cygpath arguments | ||
| 127 | + if [ "$GRADLE_CYGPATTERN" != "" ] ; then | ||
| 128 | + OURCYGPATTERN="$OURCYGPATTERN|($GRADLE_CYGPATTERN)" | ||
| 129 | + fi | ||
| 130 | + # Now convert the arguments - kludge to limit ourselves to /bin/sh | ||
| 131 | + i=0 | ||
| 132 | + for arg in "$@" ; do | ||
| 133 | + CHECK=`echo "$arg"|egrep -c "$OURCYGPATTERN" -` | ||
| 134 | + CHECK2=`echo "$arg"|egrep -c "^-"` ### Determine if an option | ||
| 135 | + | ||
| 136 | + if [ $CHECK -ne 0 ] && [ $CHECK2 -eq 0 ] ; then ### Added a condition | ||
| 137 | + eval `echo args$i`=`cygpath --path --ignore --mixed "$arg"` | ||
| 138 | + else | ||
| 139 | + eval `echo args$i`="\"$arg\"" | ||
| 140 | + fi | ||
| 141 | + i=$((i+1)) | ||
| 142 | + done | ||
| 143 | + case $i in | ||
| 144 | + (0) set -- ;; | ||
| 145 | + (1) set -- "$args0" ;; | ||
| 146 | + (2) set -- "$args0" "$args1" ;; | ||
| 147 | + (3) set -- "$args0" "$args1" "$args2" ;; | ||
| 148 | + (4) set -- "$args0" "$args1" "$args2" "$args3" ;; | ||
| 149 | + (5) set -- "$args0" "$args1" "$args2" "$args3" "$args4" ;; | ||
| 150 | + (6) set -- "$args0" "$args1" "$args2" "$args3" "$args4" "$args5" ;; | ||
| 151 | + (7) set -- "$args0" "$args1" "$args2" "$args3" "$args4" "$args5" "$args6" ;; | ||
| 152 | + (8) set -- "$args0" "$args1" "$args2" "$args3" "$args4" "$args5" "$args6" "$args7" ;; | ||
| 153 | + (9) set -- "$args0" "$args1" "$args2" "$args3" "$args4" "$args5" "$args6" "$args7" "$args8" ;; | ||
| 154 | + esac | ||
| 155 | +fi | ||
| 156 | + | ||
| 157 | +# Escape application args | ||
| 158 | +save () { | ||
| 159 | + for i do printf %s\\n "$i" | sed "s/'/'\\\\''/g;1s/^/'/;\$s/\$/' \\\\/" ; done | ||
| 160 | + echo " " | ||
| 161 | +} | ||
| 162 | +APP_ARGS=$(save "$@") | ||
| 163 | + | ||
| 164 | +# Collect all arguments for the java command, following the shell quoting and substitution rules | ||
| 165 | +eval set -- $DEFAULT_JVM_OPTS $JAVA_OPTS $GRADLE_OPTS "\"-Dorg.gradle.appname=$APP_BASE_NAME\"" -classpath "\"$CLASSPATH\"" org.gradle.wrapper.GradleWrapperMain "$APP_ARGS" | ||
| 166 | + | ||
| 167 | +# by default we should be in the correct project dir, but when run from Finder on Mac, the cwd is wrong | ||
| 168 | +if [ "$(uname)" = "Darwin" ] && [ "$HOME" = "$PWD" ]; then | ||
| 169 | + cd "$(dirname "$0")" | ||
| 170 | +fi | ||
| 171 | + | ||
| 172 | +exec "$JAVACMD" "$@" |
android/gradlew.bat
0 → 100644
| 1 | +@if "%DEBUG%" == "" @echo off | ||
| 2 | +@rem ########################################################################## | ||
| 3 | +@rem | ||
| 4 | +@rem Gradle startup script for Windows | ||
| 5 | +@rem | ||
| 6 | +@rem ########################################################################## | ||
| 7 | + | ||
| 8 | +@rem Set local scope for the variables with windows NT shell | ||
| 9 | +if "%OS%"=="Windows_NT" setlocal | ||
| 10 | + | ||
| 11 | +set DIRNAME=%~dp0 | ||
| 12 | +if "%DIRNAME%" == "" set DIRNAME=. | ||
| 13 | +set APP_BASE_NAME=%~n0 | ||
| 14 | +set APP_HOME=%DIRNAME% | ||
| 15 | + | ||
| 16 | +@rem Add default JVM options here. You can also use JAVA_OPTS and GRADLE_OPTS to pass JVM options to this script. | ||
| 17 | +set DEFAULT_JVM_OPTS= | ||
| 18 | + | ||
| 19 | +@rem Find java.exe | ||
| 20 | +if defined JAVA_HOME goto findJavaFromJavaHome | ||
| 21 | + | ||
| 22 | +set JAVA_EXE=java.exe | ||
| 23 | +%JAVA_EXE% -version >NUL 2>&1 | ||
| 24 | +if "%ERRORLEVEL%" == "0" goto init | ||
| 25 | + | ||
| 26 | +echo. | ||
| 27 | +echo ERROR: JAVA_HOME is not set and no 'java' command could be found in your PATH. | ||
| 28 | +echo. | ||
| 29 | +echo Please set the JAVA_HOME variable in your environment to match the | ||
| 30 | +echo location of your Java installation. | ||
| 31 | + | ||
| 32 | +goto fail | ||
| 33 | + | ||
| 34 | +:findJavaFromJavaHome | ||
| 35 | +set JAVA_HOME=%JAVA_HOME:"=% | ||
| 36 | +set JAVA_EXE=%JAVA_HOME%/bin/java.exe | ||
| 37 | + | ||
| 38 | +if exist "%JAVA_EXE%" goto init | ||
| 39 | + | ||
| 40 | +echo. | ||
| 41 | +echo ERROR: JAVA_HOME is set to an invalid directory: %JAVA_HOME% | ||
| 42 | +echo. | ||
| 43 | +echo Please set the JAVA_HOME variable in your environment to match the | ||
| 44 | +echo location of your Java installation. | ||
| 45 | + | ||
| 46 | +goto fail | ||
| 47 | + | ||
| 48 | +:init | ||
| 49 | +@rem Get command-line arguments, handling Windows variants | ||
| 50 | + | ||
| 51 | +if not "%OS%" == "Windows_NT" goto win9xME_args | ||
| 52 | + | ||
| 53 | +:win9xME_args | ||
| 54 | +@rem Slurp the command line arguments. | ||
| 55 | +set CMD_LINE_ARGS= | ||
| 56 | +set _SKIP=2 | ||
| 57 | + | ||
| 58 | +:win9xME_args_slurp | ||
| 59 | +if "x%~1" == "x" goto execute | ||
| 60 | + | ||
| 61 | +set CMD_LINE_ARGS=%* | ||
| 62 | + | ||
| 63 | +:execute | ||
| 64 | +@rem Setup the command line | ||
| 65 | + | ||
| 66 | +set CLASSPATH=%APP_HOME%\gradle\wrapper\gradle-wrapper.jar | ||
| 67 | + | ||
| 68 | +@rem Execute Gradle | ||
| 69 | +"%JAVA_EXE%" %DEFAULT_JVM_OPTS% %JAVA_OPTS% %GRADLE_OPTS% "-Dorg.gradle.appname=%APP_BASE_NAME%" -classpath "%CLASSPATH%" org.gradle.wrapper.GradleWrapperMain %CMD_LINE_ARGS% | ||
| 70 | + | ||
| 71 | +:end | ||
| 72 | +@rem End local scope for the variables with windows NT shell | ||
| 73 | +if "%ERRORLEVEL%"=="0" goto mainEnd | ||
| 74 | + | ||
| 75 | +:fail | ||
| 76 | +rem Set variable GRADLE_EXIT_CONSOLE if you need the _script_ return code instead of | ||
| 77 | +rem the _cmd.exe /c_ return code! | ||
| 78 | +if not "" == "%GRADLE_EXIT_CONSOLE%" exit 1 | ||
| 79 | +exit /b 1 | ||
| 80 | + | ||
| 81 | +:mainEnd | ||
| 82 | +if "%OS%"=="Windows_NT" endlocal | ||
| 83 | + | ||
| 84 | +:omega |
android/settings.gradle
0 → 100644
| 1 | +rootProject.name = 'wakelock' |
android/src/main/AndroidManifest.xml
0 → 100644
| 1 | +package wakelock.wakelock; | ||
| 2 | + | ||
| 3 | +import android.view.WindowManager; | ||
| 4 | + | ||
| 5 | +import io.flutter.plugin.common.MethodCall; | ||
| 6 | +import io.flutter.plugin.common.MethodChannel; | ||
| 7 | +import io.flutter.plugin.common.MethodChannel.MethodCallHandler; | ||
| 8 | +import io.flutter.plugin.common.MethodChannel.Result; | ||
| 9 | +import io.flutter.plugin.common.PluginRegistry.Registrar; | ||
| 10 | + | ||
| 11 | +public class WakelockPlugin implements MethodCallHandler { | ||
| 12 | + private Registrar registrar; | ||
| 13 | + | ||
| 14 | + private WakelockPlugin(Registrar registrar) { | ||
| 15 | + this.registrar = registrar; | ||
| 16 | + } | ||
| 17 | + | ||
| 18 | + public static void registerWith(Registrar registrar) { | ||
| 19 | + final MethodChannel channel = new MethodChannel(registrar.messenger(), "wakelock"); | ||
| 20 | + channel.setMethodCallHandler(new WakelockPlugin(registrar)); | ||
| 21 | + } | ||
| 22 | + | ||
| 23 | + private boolean isWakelockEnabled() { | ||
| 24 | + return (registrar.activity().getWindow().getAttributes().flags & | ||
| 25 | + WindowManager.LayoutParams.FLAG_KEEP_SCREEN_ON) != 0; | ||
| 26 | + } | ||
| 27 | + | ||
| 28 | + @Override | ||
| 29 | + public void onMethodCall(MethodCall call, Result result) { | ||
| 30 | + if (call.method.equals("toggleWakelock")) { | ||
| 31 | + final boolean enable = call.argument("enable"), enabled = isWakelockEnabled(); | ||
| 32 | + if (enable) { | ||
| 33 | + if (!enabled) | ||
| 34 | + registrar.activity().getWindow().addFlags(WindowManager.LayoutParams.FLAG_KEEP_SCREEN_ON); | ||
| 35 | + } else if (enabled) { | ||
| 36 | + registrar.activity().getWindow().clearFlags(WindowManager.LayoutParams.FLAG_KEEP_SCREEN_ON); | ||
| 37 | + } | ||
| 38 | + result.success(null); | ||
| 39 | + } else if (call.method.equals("isWakelockEnabled")) { | ||
| 40 | + result.success(isWakelockEnabled()); | ||
| 41 | + } else { | ||
| 42 | + result.notImplemented(); | ||
| 43 | + } | ||
| 44 | + } | ||
| 45 | +} |
example/.gitignore
0 → 100644
| 1 | +# Miscellaneous | ||
| 2 | +*.class | ||
| 3 | +*.log | ||
| 4 | +*.pyc | ||
| 5 | +*.swp | ||
| 6 | +.DS_Store | ||
| 7 | +.atom/ | ||
| 8 | +.buildlog/ | ||
| 9 | +.history | ||
| 10 | +.svn/ | ||
| 11 | + | ||
| 12 | +# IntelliJ related | ||
| 13 | +*.iml | ||
| 14 | +*.ipr | ||
| 15 | +*.iws | ||
| 16 | +.idea/ | ||
| 17 | + | ||
| 18 | +# The .vscode folder contains launch configuration and tasks you configure in | ||
| 19 | +# VS Code which you may wish to be included in version control, so this line | ||
| 20 | +# is commented out by default. | ||
| 21 | +#.vscode/ | ||
| 22 | + | ||
| 23 | +# Flutter/Dart/Pub related | ||
| 24 | +**/doc/api/ | ||
| 25 | +.dart_tool/ | ||
| 26 | +.flutter-plugins | ||
| 27 | +.packages | ||
| 28 | +.pub-cache/ | ||
| 29 | +.pub/ | ||
| 30 | +/build/ | ||
| 31 | + | ||
| 32 | +# Android related | ||
| 33 | +**/android/**/gradle-wrapper.jar | ||
| 34 | +**/android/.gradle | ||
| 35 | +**/android/captures/ | ||
| 36 | +**/android/gradlew | ||
| 37 | +**/android/gradlew.bat | ||
| 38 | +**/android/local.properties | ||
| 39 | +**/android/**/GeneratedPluginRegistrant.java | ||
| 40 | + | ||
| 41 | +# iOS/XCode related | ||
| 42 | +**/ios/**/*.mode1v3 | ||
| 43 | +**/ios/**/*.mode2v3 | ||
| 44 | +**/ios/**/*.moved-aside | ||
| 45 | +**/ios/**/*.pbxuser | ||
| 46 | +**/ios/**/*.perspectivev3 | ||
| 47 | +**/ios/**/*sync/ | ||
| 48 | +**/ios/**/.sconsign.dblite | ||
| 49 | +**/ios/**/.tags* | ||
| 50 | +**/ios/**/.vagrant/ | ||
| 51 | +**/ios/**/DerivedData/ | ||
| 52 | +**/ios/**/Icon? | ||
| 53 | +**/ios/**/Pods/ | ||
| 54 | +**/ios/**/.symlinks/ | ||
| 55 | +**/ios/**/profile | ||
| 56 | +**/ios/**/xcuserdata | ||
| 57 | +**/ios/.generated/ | ||
| 58 | +**/ios/Flutter/App.framework | ||
| 59 | +**/ios/Flutter/Flutter.framework | ||
| 60 | +**/ios/Flutter/Generated.xcconfig | ||
| 61 | +**/ios/Flutter/app.flx | ||
| 62 | +**/ios/Flutter/app.zip | ||
| 63 | +**/ios/Flutter/flutter_assets/ | ||
| 64 | +**/ios/ServiceDefinitions.json | ||
| 65 | +**/ios/Runner/GeneratedPluginRegistrant.* | ||
| 66 | + | ||
| 67 | +# Exceptions to above rules. | ||
| 68 | +!**/ios/**/default.mode1v3 | ||
| 69 | +!**/ios/**/default.mode2v3 | ||
| 70 | +!**/ios/**/default.pbxuser | ||
| 71 | +!**/ios/**/default.perspectivev3 | ||
| 72 | +!/packages/flutter_tools/test/data/dart_dependencies_test/**/.packages |
example/.metadata
0 → 100644
| 1 | +# This file tracks properties of this Flutter project. | ||
| 2 | +# Used by Flutter tool to assess capabilities and perform upgrades etc. | ||
| 3 | +# | ||
| 4 | +# This file should be version controlled and should not be manually edited. | ||
| 5 | + | ||
| 6 | +version: | ||
| 7 | + revision: 3bf91b543678d6dc677a9c3f1f2ea32a769ddbcb | ||
| 8 | + channel: master | ||
| 9 | + | ||
| 10 | +project_type: app |
example/README.md
0 → 100644
example/android/app/build.gradle
0 → 100644
| 1 | +def localProperties = new Properties() | ||
| 2 | +def localPropertiesFile = rootProject.file('local.properties') | ||
| 3 | +if (localPropertiesFile.exists()) { | ||
| 4 | + localPropertiesFile.withReader('UTF-8') { reader -> | ||
| 5 | + localProperties.load(reader) | ||
| 6 | + } | ||
| 7 | +} | ||
| 8 | + | ||
| 9 | +def flutterRoot = localProperties.getProperty('flutter.sdk') | ||
| 10 | +if (flutterRoot == null) { | ||
| 11 | + throw new GradleException("Flutter SDK not found. Define location with flutter.sdk in the local.properties file.") | ||
| 12 | +} | ||
| 13 | + | ||
| 14 | +def flutterVersionCode = localProperties.getProperty('flutter.versionCode') | ||
| 15 | +if (flutterVersionCode == null) { | ||
| 16 | + flutterVersionCode = '1' | ||
| 17 | +} | ||
| 18 | + | ||
| 19 | +def flutterVersionName = localProperties.getProperty('flutter.versionName') | ||
| 20 | +if (flutterVersionName == null) { | ||
| 21 | + flutterVersionName = '1.0' | ||
| 22 | +} | ||
| 23 | + | ||
| 24 | +apply plugin: 'com.android.application' | ||
| 25 | +apply from: "$flutterRoot/packages/flutter_tools/gradle/flutter.gradle" | ||
| 26 | + | ||
| 27 | +android { | ||
| 28 | + compileSdkVersion 28 | ||
| 29 | + | ||
| 30 | + lintOptions { | ||
| 31 | + disable 'InvalidPackage' | ||
| 32 | + } | ||
| 33 | + | ||
| 34 | + defaultConfig { | ||
| 35 | + // TODO: Specify your own unique Application ID (https://developer.android.com/studio/build/application-id.html). | ||
| 36 | + applicationId "wakelock.wakelock_example" | ||
| 37 | + minSdkVersion 16 | ||
| 38 | + targetSdkVersion 28 | ||
| 39 | + versionCode flutterVersionCode.toInteger() | ||
| 40 | + versionName flutterVersionName | ||
| 41 | + testInstrumentationRunner "android.support.test.runner.AndroidJUnitRunner" | ||
| 42 | + } | ||
| 43 | + | ||
| 44 | + buildTypes { | ||
| 45 | + release { | ||
| 46 | + // TODO: Add your own signing config for the release build. | ||
| 47 | + // Signing with the debug keys for now, so `flutter run --release` works. | ||
| 48 | + signingConfig signingConfigs.debug | ||
| 49 | + } | ||
| 50 | + } | ||
| 51 | +} | ||
| 52 | + | ||
| 53 | +flutter { | ||
| 54 | + source '../..' | ||
| 55 | +} | ||
| 56 | + | ||
| 57 | +dependencies { | ||
| 58 | + testImplementation 'junit:junit:4.12' | ||
| 59 | + androidTestImplementation 'com.android.support.test:runner:1.0.2' | ||
| 60 | + androidTestImplementation 'com.android.support.test.espresso:espresso-core:3.0.2' | ||
| 61 | +} |
| 1 | +<manifest xmlns:android="http://schemas.android.com/apk/res/android" | ||
| 2 | + package="wakelock.wakelock_example"> | ||
| 3 | + <!-- Flutter needs it to communicate with the running application | ||
| 4 | + to allow setting breakpoints, to provide hot reload, etc. | ||
| 5 | + --> | ||
| 6 | + <uses-permission android:name="android.permission.INTERNET"/> | ||
| 7 | +</manifest> |
| 1 | +<manifest xmlns:android="http://schemas.android.com/apk/res/android" | ||
| 2 | + package="wakelock.wakelock_example"> | ||
| 3 | + | ||
| 4 | + <!-- io.flutter.app.FlutterApplication is an android.app.Application that | ||
| 5 | + calls FlutterMain.startInitialization(this); in its onCreate method. | ||
| 6 | + In most cases you can leave this as-is, but you if you want to provide | ||
| 7 | + additional functionality it is fine to subclass or reimplement | ||
| 8 | + FlutterApplication and put your custom class here. --> | ||
| 9 | + <application | ||
| 10 | + android:name="io.flutter.app.FlutterApplication" | ||
| 11 | + android:label="wakelock_example" | ||
| 12 | + android:icon="@mipmap/ic_launcher"> | ||
| 13 | + <activity | ||
| 14 | + android:name=".MainActivity" | ||
| 15 | + android:launchMode="singleTop" | ||
| 16 | + android:theme="@style/LaunchTheme" | ||
| 17 | + android:configChanges="orientation|keyboardHidden|keyboard|screenSize|locale|layoutDirection|fontScale|screenLayout|density|uiMode" | ||
| 18 | + android:hardwareAccelerated="true" | ||
| 19 | + android:windowSoftInputMode="adjustResize"> | ||
| 20 | + <!-- This keeps the window background of the activity showing | ||
| 21 | + until Flutter renders its first frame. It can be removed if | ||
| 22 | + there is no splash screen (such as the default splash screen | ||
| 23 | + defined in @style/LaunchTheme). --> | ||
| 24 | + <meta-data | ||
| 25 | + android:name="io.flutter.app.android.SplashScreenUntilFirstFrame" | ||
| 26 | + android:value="true" /> | ||
| 27 | + <intent-filter> | ||
| 28 | + <action android:name="android.intent.action.MAIN"/> | ||
| 29 | + <category android:name="android.intent.category.LAUNCHER"/> | ||
| 30 | + </intent-filter> | ||
| 31 | + </activity> | ||
| 32 | + </application> | ||
| 33 | +</manifest> |
| 1 | +package wakelock.wakelock_example; | ||
| 2 | + | ||
| 3 | +import android.os.Bundle; | ||
| 4 | +import io.flutter.app.FlutterActivity; | ||
| 5 | +import io.flutter.plugins.GeneratedPluginRegistrant; | ||
| 6 | + | ||
| 7 | +public class MainActivity extends FlutterActivity { | ||
| 8 | + @Override | ||
| 9 | + protected void onCreate(Bundle savedInstanceState) { | ||
| 10 | + super.onCreate(savedInstanceState); | ||
| 11 | + GeneratedPluginRegistrant.registerWith(this); | ||
| 12 | + } | ||
| 13 | +} |
| 1 | +<?xml version="1.0" encoding="utf-8"?> | ||
| 2 | +<!-- Modify this file to customize your launch splash screen --> | ||
| 3 | +<layer-list xmlns:android="http://schemas.android.com/apk/res/android"> | ||
| 4 | + <item android:drawable="@android:color/white" /> | ||
| 5 | + | ||
| 6 | + <!-- You can insert your own image assets here --> | ||
| 7 | + <!-- <item> | ||
| 8 | + <bitmap | ||
| 9 | + android:gravity="center" | ||
| 10 | + android:src="@mipmap/launch_image" /> | ||
| 11 | + </item> --> | ||
| 12 | +</layer-list> |
544 Bytes
442 Bytes
721 Bytes
1.01 KB
1.41 KB
| 1 | +<?xml version="1.0" encoding="utf-8"?> | ||
| 2 | +<resources> | ||
| 3 | + <style name="LaunchTheme" parent="@android:style/Theme.Black.NoTitleBar"> | ||
| 4 | + <!-- Show a splash screen on the activity. Automatically removed when | ||
| 5 | + Flutter draws its first frame --> | ||
| 6 | + <item name="android:windowBackground">@drawable/launch_background</item> | ||
| 7 | + </style> | ||
| 8 | +</resources> |
| 1 | +<manifest xmlns:android="http://schemas.android.com/apk/res/android" | ||
| 2 | + package="wakelock.wakelock_example"> | ||
| 3 | + <!-- Flutter needs it to communicate with the running application | ||
| 4 | + to allow setting breakpoints, to provide hot reload, etc. | ||
| 5 | + --> | ||
| 6 | + <uses-permission android:name="android.permission.INTERNET"/> | ||
| 7 | +</manifest> |
example/android/build.gradle
0 → 100644
| 1 | +buildscript { | ||
| 2 | + repositories { | ||
| 3 | + google() | ||
| 4 | + jcenter() | ||
| 5 | + } | ||
| 6 | + | ||
| 7 | + dependencies { | ||
| 8 | + classpath 'com.android.tools.build:gradle:3.2.1' | ||
| 9 | + } | ||
| 10 | +} | ||
| 11 | + | ||
| 12 | +allprojects { | ||
| 13 | + repositories { | ||
| 14 | + google() | ||
| 15 | + jcenter() | ||
| 16 | + } | ||
| 17 | +} | ||
| 18 | + | ||
| 19 | +rootProject.buildDir = '../build' | ||
| 20 | +subprojects { | ||
| 21 | + project.buildDir = "${rootProject.buildDir}/${project.name}" | ||
| 22 | +} | ||
| 23 | +subprojects { | ||
| 24 | + project.evaluationDependsOn(':app') | ||
| 25 | +} | ||
| 26 | + | ||
| 27 | +task clean(type: Delete) { | ||
| 28 | + delete rootProject.buildDir | ||
| 29 | +} |
example/android/gradle.properties
0 → 100644
example/android/settings.gradle
0 → 100644
| 1 | +include ':app' | ||
| 2 | + | ||
| 3 | +def flutterProjectRoot = rootProject.projectDir.parentFile.toPath() | ||
| 4 | + | ||
| 5 | +def plugins = new Properties() | ||
| 6 | +def pluginsFile = new File(flutterProjectRoot.toFile(), '.flutter-plugins') | ||
| 7 | +if (pluginsFile.exists()) { | ||
| 8 | + pluginsFile.withReader('UTF-8') { reader -> plugins.load(reader) } | ||
| 9 | +} | ||
| 10 | + | ||
| 11 | +plugins.each { name, path -> | ||
| 12 | + def pluginDirectory = flutterProjectRoot.resolve(path).resolve('android').toFile() | ||
| 13 | + include ":$name" | ||
| 14 | + project(":$name").projectDir = pluginDirectory | ||
| 15 | +} |
example/ios/Flutter/AppFrameworkInfo.plist
0 → 100644
| 1 | +<?xml version="1.0" encoding="UTF-8"?> | ||
| 2 | +<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd"> | ||
| 3 | +<plist version="1.0"> | ||
| 4 | +<dict> | ||
| 5 | + <key>CFBundleDevelopmentRegion</key> | ||
| 6 | + <string>$(DEVELOPMENT_LANGUAGE)</string> | ||
| 7 | + <key>CFBundleExecutable</key> | ||
| 8 | + <string>App</string> | ||
| 9 | + <key>CFBundleIdentifier</key> | ||
| 10 | + <string>io.flutter.flutter.app</string> | ||
| 11 | + <key>CFBundleInfoDictionaryVersion</key> | ||
| 12 | + <string>6.0</string> | ||
| 13 | + <key>CFBundleName</key> | ||
| 14 | + <string>App</string> | ||
| 15 | + <key>CFBundlePackageType</key> | ||
| 16 | + <string>FMWK</string> | ||
| 17 | + <key>CFBundleShortVersionString</key> | ||
| 18 | + <string>1.0</string> | ||
| 19 | + <key>CFBundleSignature</key> | ||
| 20 | + <string>????</string> | ||
| 21 | + <key>CFBundleVersion</key> | ||
| 22 | + <string>1.0</string> | ||
| 23 | + <key>MinimumOSVersion</key> | ||
| 24 | + <string>8.0</string> | ||
| 25 | +</dict> | ||
| 26 | +</plist> |
example/ios/Flutter/Debug.xcconfig
0 → 100644
| 1 | +#include "Generated.xcconfig" |
example/ios/Flutter/Release.xcconfig
0 → 100644
| 1 | +#include "Generated.xcconfig" |
example/ios/Runner.xcodeproj/project.pbxproj
0 → 100644
| 1 | +// !$*UTF8*$! | ||
| 2 | +{ | ||
| 3 | + archiveVersion = 1; | ||
| 4 | + classes = { | ||
| 5 | + }; | ||
| 6 | + objectVersion = 46; | ||
| 7 | + objects = { | ||
| 8 | + | ||
| 9 | +/* Begin PBXBuildFile section */ | ||
| 10 | + 1498D2341E8E89220040F4C2 /* GeneratedPluginRegistrant.m in Sources */ = {isa = PBXBuildFile; fileRef = 1498D2331E8E89220040F4C2 /* GeneratedPluginRegistrant.m */; }; | ||
| 11 | + 3B3967161E833CAA004F5970 /* AppFrameworkInfo.plist in Resources */ = {isa = PBXBuildFile; fileRef = 3B3967151E833CAA004F5970 /* AppFrameworkInfo.plist */; }; | ||
| 12 | + 3B80C3941E831B6300D905FE /* App.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 3B80C3931E831B6300D905FE /* App.framework */; }; | ||
| 13 | + 3B80C3951E831B6300D905FE /* App.framework in Embed Frameworks */ = {isa = PBXBuildFile; fileRef = 3B80C3931E831B6300D905FE /* App.framework */; settings = {ATTRIBUTES = (CodeSignOnCopy, RemoveHeadersOnCopy, ); }; }; | ||
| 14 | + 9705A1C61CF904A100538489 /* Flutter.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 9740EEBA1CF902C7004384FC /* Flutter.framework */; }; | ||
| 15 | + 9705A1C71CF904A300538489 /* Flutter.framework in Embed Frameworks */ = {isa = PBXBuildFile; fileRef = 9740EEBA1CF902C7004384FC /* Flutter.framework */; settings = {ATTRIBUTES = (CodeSignOnCopy, RemoveHeadersOnCopy, ); }; }; | ||
| 16 | + 9740EEB41CF90195004384FC /* Debug.xcconfig in Resources */ = {isa = PBXBuildFile; fileRef = 9740EEB21CF90195004384FC /* Debug.xcconfig */; }; | ||
| 17 | + 978B8F6F1D3862AE00F588F7 /* AppDelegate.m in Sources */ = {isa = PBXBuildFile; fileRef = 7AFFD8EE1D35381100E5BB4D /* AppDelegate.m */; }; | ||
| 18 | + 97C146F31CF9000F007C117D /* main.m in Sources */ = {isa = PBXBuildFile; fileRef = 97C146F21CF9000F007C117D /* main.m */; }; | ||
| 19 | + 97C146FC1CF9000F007C117D /* Main.storyboard in Resources */ = {isa = PBXBuildFile; fileRef = 97C146FA1CF9000F007C117D /* Main.storyboard */; }; | ||
| 20 | + 97C146FE1CF9000F007C117D /* Assets.xcassets in Resources */ = {isa = PBXBuildFile; fileRef = 97C146FD1CF9000F007C117D /* Assets.xcassets */; }; | ||
| 21 | + 97C147011CF9000F007C117D /* LaunchScreen.storyboard in Resources */ = {isa = PBXBuildFile; fileRef = 97C146FF1CF9000F007C117D /* LaunchScreen.storyboard */; }; | ||
| 22 | +/* End PBXBuildFile section */ | ||
| 23 | + | ||
| 24 | +/* Begin PBXCopyFilesBuildPhase section */ | ||
| 25 | + 9705A1C41CF9048500538489 /* Embed Frameworks */ = { | ||
| 26 | + isa = PBXCopyFilesBuildPhase; | ||
| 27 | + buildActionMask = 2147483647; | ||
| 28 | + dstPath = ""; | ||
| 29 | + dstSubfolderSpec = 10; | ||
| 30 | + files = ( | ||
| 31 | + 3B80C3951E831B6300D905FE /* App.framework in Embed Frameworks */, | ||
| 32 | + 9705A1C71CF904A300538489 /* Flutter.framework in Embed Frameworks */, | ||
| 33 | + ); | ||
| 34 | + name = "Embed Frameworks"; | ||
| 35 | + runOnlyForDeploymentPostprocessing = 0; | ||
| 36 | + }; | ||
| 37 | +/* End PBXCopyFilesBuildPhase section */ | ||
| 38 | + | ||
| 39 | +/* Begin PBXFileReference section */ | ||
| 40 | + 1498D2321E8E86230040F4C2 /* GeneratedPluginRegistrant.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = GeneratedPluginRegistrant.h; sourceTree = "<group>"; }; | ||
| 41 | + 1498D2331E8E89220040F4C2 /* GeneratedPluginRegistrant.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = GeneratedPluginRegistrant.m; sourceTree = "<group>"; }; | ||
| 42 | + 3B3967151E833CAA004F5970 /* AppFrameworkInfo.plist */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.plist.xml; name = AppFrameworkInfo.plist; path = Flutter/AppFrameworkInfo.plist; sourceTree = "<group>"; }; | ||
| 43 | + 3B80C3931E831B6300D905FE /* App.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = App.framework; path = Flutter/App.framework; sourceTree = "<group>"; }; | ||
| 44 | + 7AFA3C8E1D35360C0083082E /* Release.xcconfig */ = {isa = PBXFileReference; lastKnownFileType = text.xcconfig; name = Release.xcconfig; path = Flutter/Release.xcconfig; sourceTree = "<group>"; }; | ||
| 45 | + 7AFFD8ED1D35381100E5BB4D /* AppDelegate.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = AppDelegate.h; sourceTree = "<group>"; }; | ||
| 46 | + 7AFFD8EE1D35381100E5BB4D /* AppDelegate.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = AppDelegate.m; sourceTree = "<group>"; }; | ||
| 47 | + 9740EEB21CF90195004384FC /* Debug.xcconfig */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.xcconfig; name = Debug.xcconfig; path = Flutter/Debug.xcconfig; sourceTree = "<group>"; }; | ||
| 48 | + 9740EEB31CF90195004384FC /* Generated.xcconfig */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.xcconfig; name = Generated.xcconfig; path = Flutter/Generated.xcconfig; sourceTree = "<group>"; }; | ||
| 49 | + 9740EEBA1CF902C7004384FC /* Flutter.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = Flutter.framework; path = Flutter/Flutter.framework; sourceTree = "<group>"; }; | ||
| 50 | + 97C146EE1CF9000F007C117D /* Runner.app */ = {isa = PBXFileReference; explicitFileType = wrapper.application; includeInIndex = 0; path = Runner.app; sourceTree = BUILT_PRODUCTS_DIR; }; | ||
| 51 | + 97C146F21CF9000F007C117D /* main.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = main.m; sourceTree = "<group>"; }; | ||
| 52 | + 97C146FB1CF9000F007C117D /* Base */ = {isa = PBXFileReference; lastKnownFileType = file.storyboard; name = Base; path = Base.lproj/Main.storyboard; sourceTree = "<group>"; }; | ||
| 53 | + 97C146FD1CF9000F007C117D /* Assets.xcassets */ = {isa = PBXFileReference; lastKnownFileType = folder.assetcatalog; path = Assets.xcassets; sourceTree = "<group>"; }; | ||
| 54 | + 97C147001CF9000F007C117D /* Base */ = {isa = PBXFileReference; lastKnownFileType = file.storyboard; name = Base; path = Base.lproj/LaunchScreen.storyboard; sourceTree = "<group>"; }; | ||
| 55 | + 97C147021CF9000F007C117D /* Info.plist */ = {isa = PBXFileReference; lastKnownFileType = text.plist.xml; path = Info.plist; sourceTree = "<group>"; }; | ||
| 56 | +/* End PBXFileReference section */ | ||
| 57 | + | ||
| 58 | +/* Begin PBXFrameworksBuildPhase section */ | ||
| 59 | + 97C146EB1CF9000F007C117D /* Frameworks */ = { | ||
| 60 | + isa = PBXFrameworksBuildPhase; | ||
| 61 | + buildActionMask = 2147483647; | ||
| 62 | + files = ( | ||
| 63 | + 9705A1C61CF904A100538489 /* Flutter.framework in Frameworks */, | ||
| 64 | + 3B80C3941E831B6300D905FE /* App.framework in Frameworks */, | ||
| 65 | + ); | ||
| 66 | + runOnlyForDeploymentPostprocessing = 0; | ||
| 67 | + }; | ||
| 68 | +/* End PBXFrameworksBuildPhase section */ | ||
| 69 | + | ||
| 70 | +/* Begin PBXGroup section */ | ||
| 71 | + 9740EEB11CF90186004384FC /* Flutter */ = { | ||
| 72 | + isa = PBXGroup; | ||
| 73 | + children = ( | ||
| 74 | + 3B80C3931E831B6300D905FE /* App.framework */, | ||
| 75 | + 3B3967151E833CAA004F5970 /* AppFrameworkInfo.plist */, | ||
| 76 | + 9740EEBA1CF902C7004384FC /* Flutter.framework */, | ||
| 77 | + 9740EEB21CF90195004384FC /* Debug.xcconfig */, | ||
| 78 | + 7AFA3C8E1D35360C0083082E /* Release.xcconfig */, | ||
| 79 | + 9740EEB31CF90195004384FC /* Generated.xcconfig */, | ||
| 80 | + ); | ||
| 81 | + name = Flutter; | ||
| 82 | + sourceTree = "<group>"; | ||
| 83 | + }; | ||
| 84 | + 97C146E51CF9000F007C117D = { | ||
| 85 | + isa = PBXGroup; | ||
| 86 | + children = ( | ||
| 87 | + 9740EEB11CF90186004384FC /* Flutter */, | ||
| 88 | + 97C146F01CF9000F007C117D /* Runner */, | ||
| 89 | + 97C146EF1CF9000F007C117D /* Products */, | ||
| 90 | + CF3B75C9A7D2FA2A4C99F110 /* Frameworks */, | ||
| 91 | + ); | ||
| 92 | + sourceTree = "<group>"; | ||
| 93 | + }; | ||
| 94 | + 97C146EF1CF9000F007C117D /* Products */ = { | ||
| 95 | + isa = PBXGroup; | ||
| 96 | + children = ( | ||
| 97 | + 97C146EE1CF9000F007C117D /* Runner.app */, | ||
| 98 | + ); | ||
| 99 | + name = Products; | ||
| 100 | + sourceTree = "<group>"; | ||
| 101 | + }; | ||
| 102 | + 97C146F01CF9000F007C117D /* Runner */ = { | ||
| 103 | + isa = PBXGroup; | ||
| 104 | + children = ( | ||
| 105 | + 7AFFD8ED1D35381100E5BB4D /* AppDelegate.h */, | ||
| 106 | + 7AFFD8EE1D35381100E5BB4D /* AppDelegate.m */, | ||
| 107 | + 97C146FA1CF9000F007C117D /* Main.storyboard */, | ||
| 108 | + 97C146FD1CF9000F007C117D /* Assets.xcassets */, | ||
| 109 | + 97C146FF1CF9000F007C117D /* LaunchScreen.storyboard */, | ||
| 110 | + 97C147021CF9000F007C117D /* Info.plist */, | ||
| 111 | + 97C146F11CF9000F007C117D /* Supporting Files */, | ||
| 112 | + 1498D2321E8E86230040F4C2 /* GeneratedPluginRegistrant.h */, | ||
| 113 | + 1498D2331E8E89220040F4C2 /* GeneratedPluginRegistrant.m */, | ||
| 114 | + ); | ||
| 115 | + path = Runner; | ||
| 116 | + sourceTree = "<group>"; | ||
| 117 | + }; | ||
| 118 | + 97C146F11CF9000F007C117D /* Supporting Files */ = { | ||
| 119 | + isa = PBXGroup; | ||
| 120 | + children = ( | ||
| 121 | + 97C146F21CF9000F007C117D /* main.m */, | ||
| 122 | + ); | ||
| 123 | + name = "Supporting Files"; | ||
| 124 | + sourceTree = "<group>"; | ||
| 125 | + }; | ||
| 126 | +/* End PBXGroup section */ | ||
| 127 | + | ||
| 128 | +/* Begin PBXNativeTarget section */ | ||
| 129 | + 97C146ED1CF9000F007C117D /* Runner */ = { | ||
| 130 | + isa = PBXNativeTarget; | ||
| 131 | + buildConfigurationList = 97C147051CF9000F007C117D /* Build configuration list for PBXNativeTarget "Runner" */; | ||
| 132 | + buildPhases = ( | ||
| 133 | + 9740EEB61CF901F6004384FC /* Run Script */, | ||
| 134 | + 97C146EA1CF9000F007C117D /* Sources */, | ||
| 135 | + 97C146EB1CF9000F007C117D /* Frameworks */, | ||
| 136 | + 97C146EC1CF9000F007C117D /* Resources */, | ||
| 137 | + 9705A1C41CF9048500538489 /* Embed Frameworks */, | ||
| 138 | + 3B06AD1E1E4923F5004D2608 /* Thin Binary */, | ||
| 139 | + ); | ||
| 140 | + buildRules = ( | ||
| 141 | + ); | ||
| 142 | + dependencies = ( | ||
| 143 | + ); | ||
| 144 | + name = Runner; | ||
| 145 | + productName = Runner; | ||
| 146 | + productReference = 97C146EE1CF9000F007C117D /* Runner.app */; | ||
| 147 | + productType = "com.apple.product-type.application"; | ||
| 148 | + }; | ||
| 149 | +/* End PBXNativeTarget section */ | ||
| 150 | + | ||
| 151 | +/* Begin PBXProject section */ | ||
| 152 | + 97C146E61CF9000F007C117D /* Project object */ = { | ||
| 153 | + isa = PBXProject; | ||
| 154 | + attributes = { | ||
| 155 | + LastUpgradeCheck = 1020; | ||
| 156 | + ORGANIZATIONNAME = "The Chromium Authors"; | ||
| 157 | + TargetAttributes = { | ||
| 158 | + 97C146ED1CF9000F007C117D = { | ||
| 159 | + CreatedOnToolsVersion = 7.3.1; | ||
| 160 | + }; | ||
| 161 | + }; | ||
| 162 | + }; | ||
| 163 | + buildConfigurationList = 97C146E91CF9000F007C117D /* Build configuration list for PBXProject "Runner" */; | ||
| 164 | + compatibilityVersion = "Xcode 3.2"; | ||
| 165 | + developmentRegion = en; | ||
| 166 | + hasScannedForEncodings = 0; | ||
| 167 | + knownRegions = ( | ||
| 168 | + en, | ||
| 169 | + Base, | ||
| 170 | + ); | ||
| 171 | + mainGroup = 97C146E51CF9000F007C117D; | ||
| 172 | + productRefGroup = 97C146EF1CF9000F007C117D /* Products */; | ||
| 173 | + projectDirPath = ""; | ||
| 174 | + projectRoot = ""; | ||
| 175 | + targets = ( | ||
| 176 | + 97C146ED1CF9000F007C117D /* Runner */, | ||
| 177 | + ); | ||
| 178 | + }; | ||
| 179 | +/* End PBXProject section */ | ||
| 180 | + | ||
| 181 | +/* Begin PBXResourcesBuildPhase section */ | ||
| 182 | + 97C146EC1CF9000F007C117D /* Resources */ = { | ||
| 183 | + isa = PBXResourcesBuildPhase; | ||
| 184 | + buildActionMask = 2147483647; | ||
| 185 | + files = ( | ||
| 186 | + 97C147011CF9000F007C117D /* LaunchScreen.storyboard in Resources */, | ||
| 187 | + 3B3967161E833CAA004F5970 /* AppFrameworkInfo.plist in Resources */, | ||
| 188 | + 9740EEB41CF90195004384FC /* Debug.xcconfig in Resources */, | ||
| 189 | + 97C146FE1CF9000F007C117D /* Assets.xcassets in Resources */, | ||
| 190 | + 97C146FC1CF9000F007C117D /* Main.storyboard in Resources */, | ||
| 191 | + ); | ||
| 192 | + runOnlyForDeploymentPostprocessing = 0; | ||
| 193 | + }; | ||
| 194 | +/* End PBXResourcesBuildPhase section */ | ||
| 195 | + | ||
| 196 | +/* Begin PBXShellScriptBuildPhase section */ | ||
| 197 | + 3B06AD1E1E4923F5004D2608 /* Thin Binary */ = { | ||
| 198 | + isa = PBXShellScriptBuildPhase; | ||
| 199 | + buildActionMask = 2147483647; | ||
| 200 | + files = ( | ||
| 201 | + ); | ||
| 202 | + inputPaths = ( | ||
| 203 | + ); | ||
| 204 | + name = "Thin Binary"; | ||
| 205 | + outputPaths = ( | ||
| 206 | + ); | ||
| 207 | + runOnlyForDeploymentPostprocessing = 0; | ||
| 208 | + shellPath = /bin/sh; | ||
| 209 | + shellScript = "/bin/sh \"$FLUTTER_ROOT/packages/flutter_tools/bin/xcode_backend.sh\" thin"; | ||
| 210 | + }; | ||
| 211 | + 9740EEB61CF901F6004384FC /* Run Script */ = { | ||
| 212 | + isa = PBXShellScriptBuildPhase; | ||
| 213 | + buildActionMask = 2147483647; | ||
| 214 | + files = ( | ||
| 215 | + ); | ||
| 216 | + inputPaths = ( | ||
| 217 | + ); | ||
| 218 | + name = "Run Script"; | ||
| 219 | + outputPaths = ( | ||
| 220 | + ); | ||
| 221 | + runOnlyForDeploymentPostprocessing = 0; | ||
| 222 | + shellPath = /bin/sh; | ||
| 223 | + shellScript = "/bin/sh \"$FLUTTER_ROOT/packages/flutter_tools/bin/xcode_backend.sh\" build"; | ||
| 224 | + }; | ||
| 225 | +/* End PBXShellScriptBuildPhase section */ | ||
| 226 | + | ||
| 227 | +/* Begin PBXSourcesBuildPhase section */ | ||
| 228 | + 97C146EA1CF9000F007C117D /* Sources */ = { | ||
| 229 | + isa = PBXSourcesBuildPhase; | ||
| 230 | + buildActionMask = 2147483647; | ||
| 231 | + files = ( | ||
| 232 | + 978B8F6F1D3862AE00F588F7 /* AppDelegate.m in Sources */, | ||
| 233 | + 97C146F31CF9000F007C117D /* main.m in Sources */, | ||
| 234 | + 1498D2341E8E89220040F4C2 /* GeneratedPluginRegistrant.m in Sources */, | ||
| 235 | + ); | ||
| 236 | + runOnlyForDeploymentPostprocessing = 0; | ||
| 237 | + }; | ||
| 238 | +/* End PBXSourcesBuildPhase section */ | ||
| 239 | + | ||
| 240 | +/* Begin PBXVariantGroup section */ | ||
| 241 | + 97C146FA1CF9000F007C117D /* Main.storyboard */ = { | ||
| 242 | + isa = PBXVariantGroup; | ||
| 243 | + children = ( | ||
| 244 | + 97C146FB1CF9000F007C117D /* Base */, | ||
| 245 | + ); | ||
| 246 | + name = Main.storyboard; | ||
| 247 | + sourceTree = "<group>"; | ||
| 248 | + }; | ||
| 249 | + 97C146FF1CF9000F007C117D /* LaunchScreen.storyboard */ = { | ||
| 250 | + isa = PBXVariantGroup; | ||
| 251 | + children = ( | ||
| 252 | + 97C147001CF9000F007C117D /* Base */, | ||
| 253 | + ); | ||
| 254 | + name = LaunchScreen.storyboard; | ||
| 255 | + sourceTree = "<group>"; | ||
| 256 | + }; | ||
| 257 | +/* End PBXVariantGroup section */ | ||
| 258 | + | ||
| 259 | +/* Begin XCBuildConfiguration section */ | ||
| 260 | + 249021D3217E4FDB00AE95B9 /* Profile */ = { | ||
| 261 | + isa = XCBuildConfiguration; | ||
| 262 | + baseConfigurationReference = 7AFA3C8E1D35360C0083082E /* Release.xcconfig */; | ||
| 263 | + buildSettings = { | ||
| 264 | + ALWAYS_SEARCH_USER_PATHS = NO; | ||
| 265 | + CLANG_ANALYZER_NONNULL = YES; | ||
| 266 | + CLANG_CXX_LANGUAGE_STANDARD = "gnu++0x"; | ||
| 267 | + CLANG_CXX_LIBRARY = "libc++"; | ||
| 268 | + CLANG_ENABLE_MODULES = YES; | ||
| 269 | + CLANG_ENABLE_OBJC_ARC = YES; | ||
| 270 | + CLANG_WARN_BLOCK_CAPTURE_AUTORELEASING = YES; | ||
| 271 | + CLANG_WARN_BOOL_CONVERSION = YES; | ||
| 272 | + CLANG_WARN_COMMA = YES; | ||
| 273 | + CLANG_WARN_CONSTANT_CONVERSION = YES; | ||
| 274 | + CLANG_WARN_DEPRECATED_OBJC_IMPLEMENTATIONS = YES; | ||
| 275 | + CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR; | ||
| 276 | + CLANG_WARN_EMPTY_BODY = YES; | ||
| 277 | + CLANG_WARN_ENUM_CONVERSION = YES; | ||
| 278 | + CLANG_WARN_INFINITE_RECURSION = YES; | ||
| 279 | + CLANG_WARN_INT_CONVERSION = YES; | ||
| 280 | + CLANG_WARN_NON_LITERAL_NULL_CONVERSION = YES; | ||
| 281 | + CLANG_WARN_OBJC_IMPLICIT_RETAIN_SELF = YES; | ||
| 282 | + CLANG_WARN_OBJC_LITERAL_CONVERSION = YES; | ||
| 283 | + CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR; | ||
| 284 | + CLANG_WARN_RANGE_LOOP_ANALYSIS = YES; | ||
| 285 | + CLANG_WARN_STRICT_PROTOTYPES = YES; | ||
| 286 | + CLANG_WARN_SUSPICIOUS_MOVE = YES; | ||
| 287 | + CLANG_WARN_UNREACHABLE_CODE = YES; | ||
| 288 | + CLANG_WARN__DUPLICATE_METHOD_MATCH = YES; | ||
| 289 | + "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer"; | ||
| 290 | + COPY_PHASE_STRIP = NO; | ||
| 291 | + DEBUG_INFORMATION_FORMAT = "dwarf-with-dsym"; | ||
| 292 | + ENABLE_NS_ASSERTIONS = NO; | ||
| 293 | + ENABLE_STRICT_OBJC_MSGSEND = YES; | ||
| 294 | + GCC_C_LANGUAGE_STANDARD = gnu99; | ||
| 295 | + GCC_NO_COMMON_BLOCKS = YES; | ||
| 296 | + GCC_WARN_64_TO_32_BIT_CONVERSION = YES; | ||
| 297 | + GCC_WARN_ABOUT_RETURN_TYPE = YES_ERROR; | ||
| 298 | + GCC_WARN_UNDECLARED_SELECTOR = YES; | ||
| 299 | + GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE; | ||
| 300 | + GCC_WARN_UNUSED_FUNCTION = YES; | ||
| 301 | + GCC_WARN_UNUSED_VARIABLE = YES; | ||
| 302 | + IPHONEOS_DEPLOYMENT_TARGET = 8.0; | ||
| 303 | + MTL_ENABLE_DEBUG_INFO = NO; | ||
| 304 | + SDKROOT = iphoneos; | ||
| 305 | + TARGETED_DEVICE_FAMILY = "1,2"; | ||
| 306 | + VALIDATE_PRODUCT = YES; | ||
| 307 | + }; | ||
| 308 | + name = Profile; | ||
| 309 | + }; | ||
| 310 | + 249021D4217E4FDB00AE95B9 /* Profile */ = { | ||
| 311 | + isa = XCBuildConfiguration; | ||
| 312 | + baseConfigurationReference = 7AFA3C8E1D35360C0083082E /* Release.xcconfig */; | ||
| 313 | + buildSettings = { | ||
| 314 | + ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon; | ||
| 315 | + CURRENT_PROJECT_VERSION = "$(FLUTTER_BUILD_NUMBER)"; | ||
| 316 | + DEVELOPMENT_TEAM = S8QB4VV633; | ||
| 317 | + ENABLE_BITCODE = NO; | ||
| 318 | + FRAMEWORK_SEARCH_PATHS = ( | ||
| 319 | + "$(inherited)", | ||
| 320 | + "$(PROJECT_DIR)/Flutter", | ||
| 321 | + ); | ||
| 322 | + INFOPLIST_FILE = Runner/Info.plist; | ||
| 323 | + LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks"; | ||
| 324 | + LIBRARY_SEARCH_PATHS = ( | ||
| 325 | + "$(inherited)", | ||
| 326 | + "$(PROJECT_DIR)/Flutter", | ||
| 327 | + ); | ||
| 328 | + PRODUCT_BUNDLE_IDENTIFIER = wakelock.wakelockExample; | ||
| 329 | + PRODUCT_NAME = "$(TARGET_NAME)"; | ||
| 330 | + VERSIONING_SYSTEM = "apple-generic"; | ||
| 331 | + }; | ||
| 332 | + name = Profile; | ||
| 333 | + }; | ||
| 334 | + 97C147031CF9000F007C117D /* Debug */ = { | ||
| 335 | + isa = XCBuildConfiguration; | ||
| 336 | + baseConfigurationReference = 9740EEB21CF90195004384FC /* Debug.xcconfig */; | ||
| 337 | + buildSettings = { | ||
| 338 | + ALWAYS_SEARCH_USER_PATHS = NO; | ||
| 339 | + CLANG_ANALYZER_NONNULL = YES; | ||
| 340 | + CLANG_CXX_LANGUAGE_STANDARD = "gnu++0x"; | ||
| 341 | + CLANG_CXX_LIBRARY = "libc++"; | ||
| 342 | + CLANG_ENABLE_MODULES = YES; | ||
| 343 | + CLANG_ENABLE_OBJC_ARC = YES; | ||
| 344 | + CLANG_WARN_BLOCK_CAPTURE_AUTORELEASING = YES; | ||
| 345 | + CLANG_WARN_BOOL_CONVERSION = YES; | ||
| 346 | + CLANG_WARN_COMMA = YES; | ||
| 347 | + CLANG_WARN_CONSTANT_CONVERSION = YES; | ||
| 348 | + CLANG_WARN_DEPRECATED_OBJC_IMPLEMENTATIONS = YES; | ||
| 349 | + CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR; | ||
| 350 | + CLANG_WARN_EMPTY_BODY = YES; | ||
| 351 | + CLANG_WARN_ENUM_CONVERSION = YES; | ||
| 352 | + CLANG_WARN_INFINITE_RECURSION = YES; | ||
| 353 | + CLANG_WARN_INT_CONVERSION = YES; | ||
| 354 | + CLANG_WARN_NON_LITERAL_NULL_CONVERSION = YES; | ||
| 355 | + CLANG_WARN_OBJC_IMPLICIT_RETAIN_SELF = YES; | ||
| 356 | + CLANG_WARN_OBJC_LITERAL_CONVERSION = YES; | ||
| 357 | + CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR; | ||
| 358 | + CLANG_WARN_RANGE_LOOP_ANALYSIS = YES; | ||
| 359 | + CLANG_WARN_STRICT_PROTOTYPES = YES; | ||
| 360 | + CLANG_WARN_SUSPICIOUS_MOVE = YES; | ||
| 361 | + CLANG_WARN_UNREACHABLE_CODE = YES; | ||
| 362 | + CLANG_WARN__DUPLICATE_METHOD_MATCH = YES; | ||
| 363 | + "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer"; | ||
| 364 | + COPY_PHASE_STRIP = NO; | ||
| 365 | + DEBUG_INFORMATION_FORMAT = dwarf; | ||
| 366 | + ENABLE_STRICT_OBJC_MSGSEND = YES; | ||
| 367 | + ENABLE_TESTABILITY = YES; | ||
| 368 | + GCC_C_LANGUAGE_STANDARD = gnu99; | ||
| 369 | + GCC_DYNAMIC_NO_PIC = NO; | ||
| 370 | + GCC_NO_COMMON_BLOCKS = YES; | ||
| 371 | + GCC_OPTIMIZATION_LEVEL = 0; | ||
| 372 | + GCC_PREPROCESSOR_DEFINITIONS = ( | ||
| 373 | + "DEBUG=1", | ||
| 374 | + "$(inherited)", | ||
| 375 | + ); | ||
| 376 | + GCC_WARN_64_TO_32_BIT_CONVERSION = YES; | ||
| 377 | + GCC_WARN_ABOUT_RETURN_TYPE = YES_ERROR; | ||
| 378 | + GCC_WARN_UNDECLARED_SELECTOR = YES; | ||
| 379 | + GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE; | ||
| 380 | + GCC_WARN_UNUSED_FUNCTION = YES; | ||
| 381 | + GCC_WARN_UNUSED_VARIABLE = YES; | ||
| 382 | + IPHONEOS_DEPLOYMENT_TARGET = 8.0; | ||
| 383 | + MTL_ENABLE_DEBUG_INFO = YES; | ||
| 384 | + ONLY_ACTIVE_ARCH = YES; | ||
| 385 | + SDKROOT = iphoneos; | ||
| 386 | + TARGETED_DEVICE_FAMILY = "1,2"; | ||
| 387 | + }; | ||
| 388 | + name = Debug; | ||
| 389 | + }; | ||
| 390 | + 97C147041CF9000F007C117D /* Release */ = { | ||
| 391 | + isa = XCBuildConfiguration; | ||
| 392 | + baseConfigurationReference = 7AFA3C8E1D35360C0083082E /* Release.xcconfig */; | ||
| 393 | + buildSettings = { | ||
| 394 | + ALWAYS_SEARCH_USER_PATHS = NO; | ||
| 395 | + CLANG_ANALYZER_NONNULL = YES; | ||
| 396 | + CLANG_CXX_LANGUAGE_STANDARD = "gnu++0x"; | ||
| 397 | + CLANG_CXX_LIBRARY = "libc++"; | ||
| 398 | + CLANG_ENABLE_MODULES = YES; | ||
| 399 | + CLANG_ENABLE_OBJC_ARC = YES; | ||
| 400 | + CLANG_WARN_BLOCK_CAPTURE_AUTORELEASING = YES; | ||
| 401 | + CLANG_WARN_BOOL_CONVERSION = YES; | ||
| 402 | + CLANG_WARN_COMMA = YES; | ||
| 403 | + CLANG_WARN_CONSTANT_CONVERSION = YES; | ||
| 404 | + CLANG_WARN_DEPRECATED_OBJC_IMPLEMENTATIONS = YES; | ||
| 405 | + CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR; | ||
| 406 | + CLANG_WARN_EMPTY_BODY = YES; | ||
| 407 | + CLANG_WARN_ENUM_CONVERSION = YES; | ||
| 408 | + CLANG_WARN_INFINITE_RECURSION = YES; | ||
| 409 | + CLANG_WARN_INT_CONVERSION = YES; | ||
| 410 | + CLANG_WARN_NON_LITERAL_NULL_CONVERSION = YES; | ||
| 411 | + CLANG_WARN_OBJC_IMPLICIT_RETAIN_SELF = YES; | ||
| 412 | + CLANG_WARN_OBJC_LITERAL_CONVERSION = YES; | ||
| 413 | + CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR; | ||
| 414 | + CLANG_WARN_RANGE_LOOP_ANALYSIS = YES; | ||
| 415 | + CLANG_WARN_STRICT_PROTOTYPES = YES; | ||
| 416 | + CLANG_WARN_SUSPICIOUS_MOVE = YES; | ||
| 417 | + CLANG_WARN_UNREACHABLE_CODE = YES; | ||
| 418 | + CLANG_WARN__DUPLICATE_METHOD_MATCH = YES; | ||
| 419 | + "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer"; | ||
| 420 | + COPY_PHASE_STRIP = NO; | ||
| 421 | + DEBUG_INFORMATION_FORMAT = "dwarf-with-dsym"; | ||
| 422 | + ENABLE_NS_ASSERTIONS = NO; | ||
| 423 | + ENABLE_STRICT_OBJC_MSGSEND = YES; | ||
| 424 | + GCC_C_LANGUAGE_STANDARD = gnu99; | ||
| 425 | + GCC_NO_COMMON_BLOCKS = YES; | ||
| 426 | + GCC_WARN_64_TO_32_BIT_CONVERSION = YES; | ||
| 427 | + GCC_WARN_ABOUT_RETURN_TYPE = YES_ERROR; | ||
| 428 | + GCC_WARN_UNDECLARED_SELECTOR = YES; | ||
| 429 | + GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE; | ||
| 430 | + GCC_WARN_UNUSED_FUNCTION = YES; | ||
| 431 | + GCC_WARN_UNUSED_VARIABLE = YES; | ||
| 432 | + IPHONEOS_DEPLOYMENT_TARGET = 8.0; | ||
| 433 | + MTL_ENABLE_DEBUG_INFO = NO; | ||
| 434 | + SDKROOT = iphoneos; | ||
| 435 | + TARGETED_DEVICE_FAMILY = "1,2"; | ||
| 436 | + VALIDATE_PRODUCT = YES; | ||
| 437 | + }; | ||
| 438 | + name = Release; | ||
| 439 | + }; | ||
| 440 | + 97C147061CF9000F007C117D /* Debug */ = { | ||
| 441 | + isa = XCBuildConfiguration; | ||
| 442 | + baseConfigurationReference = 9740EEB21CF90195004384FC /* Debug.xcconfig */; | ||
| 443 | + buildSettings = { | ||
| 444 | + ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon; | ||
| 445 | + CURRENT_PROJECT_VERSION = "$(FLUTTER_BUILD_NUMBER)"; | ||
| 446 | + ENABLE_BITCODE = NO; | ||
| 447 | + FRAMEWORK_SEARCH_PATHS = ( | ||
| 448 | + "$(inherited)", | ||
| 449 | + "$(PROJECT_DIR)/Flutter", | ||
| 450 | + ); | ||
| 451 | + INFOPLIST_FILE = Runner/Info.plist; | ||
| 452 | + LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks"; | ||
| 453 | + LIBRARY_SEARCH_PATHS = ( | ||
| 454 | + "$(inherited)", | ||
| 455 | + "$(PROJECT_DIR)/Flutter", | ||
| 456 | + ); | ||
| 457 | + PRODUCT_BUNDLE_IDENTIFIER = wakelock.wakelockExample; | ||
| 458 | + PRODUCT_NAME = "$(TARGET_NAME)"; | ||
| 459 | + VERSIONING_SYSTEM = "apple-generic"; | ||
| 460 | + }; | ||
| 461 | + name = Debug; | ||
| 462 | + }; | ||
| 463 | + 97C147071CF9000F007C117D /* Release */ = { | ||
| 464 | + isa = XCBuildConfiguration; | ||
| 465 | + baseConfigurationReference = 7AFA3C8E1D35360C0083082E /* Release.xcconfig */; | ||
| 466 | + buildSettings = { | ||
| 467 | + ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon; | ||
| 468 | + CURRENT_PROJECT_VERSION = "$(FLUTTER_BUILD_NUMBER)"; | ||
| 469 | + ENABLE_BITCODE = NO; | ||
| 470 | + FRAMEWORK_SEARCH_PATHS = ( | ||
| 471 | + "$(inherited)", | ||
| 472 | + "$(PROJECT_DIR)/Flutter", | ||
| 473 | + ); | ||
| 474 | + INFOPLIST_FILE = Runner/Info.plist; | ||
| 475 | + LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks"; | ||
| 476 | + LIBRARY_SEARCH_PATHS = ( | ||
| 477 | + "$(inherited)", | ||
| 478 | + "$(PROJECT_DIR)/Flutter", | ||
| 479 | + ); | ||
| 480 | + PRODUCT_BUNDLE_IDENTIFIER = wakelock.wakelockExample; | ||
| 481 | + PRODUCT_NAME = "$(TARGET_NAME)"; | ||
| 482 | + VERSIONING_SYSTEM = "apple-generic"; | ||
| 483 | + }; | ||
| 484 | + name = Release; | ||
| 485 | + }; | ||
| 486 | +/* End XCBuildConfiguration section */ | ||
| 487 | + | ||
| 488 | +/* Begin XCConfigurationList section */ | ||
| 489 | + 97C146E91CF9000F007C117D /* Build configuration list for PBXProject "Runner" */ = { | ||
| 490 | + isa = XCConfigurationList; | ||
| 491 | + buildConfigurations = ( | ||
| 492 | + 97C147031CF9000F007C117D /* Debug */, | ||
| 493 | + 97C147041CF9000F007C117D /* Release */, | ||
| 494 | + 249021D3217E4FDB00AE95B9 /* Profile */, | ||
| 495 | + ); | ||
| 496 | + defaultConfigurationIsVisible = 0; | ||
| 497 | + defaultConfigurationName = Release; | ||
| 498 | + }; | ||
| 499 | + 97C147051CF9000F007C117D /* Build configuration list for PBXNativeTarget "Runner" */ = { | ||
| 500 | + isa = XCConfigurationList; | ||
| 501 | + buildConfigurations = ( | ||
| 502 | + 97C147061CF9000F007C117D /* Debug */, | ||
| 503 | + 97C147071CF9000F007C117D /* Release */, | ||
| 504 | + 249021D4217E4FDB00AE95B9 /* Profile */, | ||
| 505 | + ); | ||
| 506 | + defaultConfigurationIsVisible = 0; | ||
| 507 | + defaultConfigurationName = Release; | ||
| 508 | + }; | ||
| 509 | +/* End XCConfigurationList section */ | ||
| 510 | + }; | ||
| 511 | + rootObject = 97C146E61CF9000F007C117D /* Project object */; | ||
| 512 | +} |
| 1 | +<?xml version="1.0" encoding="UTF-8"?> | ||
| 2 | +<Scheme | ||
| 3 | + LastUpgradeVersion = "1020" | ||
| 4 | + version = "1.3"> | ||
| 5 | + <BuildAction | ||
| 6 | + parallelizeBuildables = "YES" | ||
| 7 | + buildImplicitDependencies = "YES"> | ||
| 8 | + <BuildActionEntries> | ||
| 9 | + <BuildActionEntry | ||
| 10 | + buildForTesting = "YES" | ||
| 11 | + buildForRunning = "YES" | ||
| 12 | + buildForProfiling = "YES" | ||
| 13 | + buildForArchiving = "YES" | ||
| 14 | + buildForAnalyzing = "YES"> | ||
| 15 | + <BuildableReference | ||
| 16 | + BuildableIdentifier = "primary" | ||
| 17 | + BlueprintIdentifier = "97C146ED1CF9000F007C117D" | ||
| 18 | + BuildableName = "Runner.app" | ||
| 19 | + BlueprintName = "Runner" | ||
| 20 | + ReferencedContainer = "container:Runner.xcodeproj"> | ||
| 21 | + </BuildableReference> | ||
| 22 | + </BuildActionEntry> | ||
| 23 | + </BuildActionEntries> | ||
| 24 | + </BuildAction> | ||
| 25 | + <TestAction | ||
| 26 | + buildConfiguration = "Debug" | ||
| 27 | + selectedDebuggerIdentifier = "Xcode.DebuggerFoundation.Debugger.LLDB" | ||
| 28 | + selectedLauncherIdentifier = "Xcode.DebuggerFoundation.Launcher.LLDB" | ||
| 29 | + shouldUseLaunchSchemeArgsEnv = "YES"> | ||
| 30 | + <Testables> | ||
| 31 | + </Testables> | ||
| 32 | + <MacroExpansion> | ||
| 33 | + <BuildableReference | ||
| 34 | + BuildableIdentifier = "primary" | ||
| 35 | + BlueprintIdentifier = "97C146ED1CF9000F007C117D" | ||
| 36 | + BuildableName = "Runner.app" | ||
| 37 | + BlueprintName = "Runner" | ||
| 38 | + ReferencedContainer = "container:Runner.xcodeproj"> | ||
| 39 | + </BuildableReference> | ||
| 40 | + </MacroExpansion> | ||
| 41 | + <AdditionalOptions> | ||
| 42 | + </AdditionalOptions> | ||
| 43 | + </TestAction> | ||
| 44 | + <LaunchAction | ||
| 45 | + buildConfiguration = "Debug" | ||
| 46 | + selectedDebuggerIdentifier = "Xcode.DebuggerFoundation.Debugger.LLDB" | ||
| 47 | + selectedLauncherIdentifier = "Xcode.DebuggerFoundation.Launcher.LLDB" | ||
| 48 | + launchStyle = "0" | ||
| 49 | + useCustomWorkingDirectory = "NO" | ||
| 50 | + ignoresPersistentStateOnLaunch = "NO" | ||
| 51 | + debugDocumentVersioning = "YES" | ||
| 52 | + debugServiceExtension = "internal" | ||
| 53 | + allowLocationSimulation = "YES"> | ||
| 54 | + <BuildableProductRunnable | ||
| 55 | + runnableDebuggingMode = "0"> | ||
| 56 | + <BuildableReference | ||
| 57 | + BuildableIdentifier = "primary" | ||
| 58 | + BlueprintIdentifier = "97C146ED1CF9000F007C117D" | ||
| 59 | + BuildableName = "Runner.app" | ||
| 60 | + BlueprintName = "Runner" | ||
| 61 | + ReferencedContainer = "container:Runner.xcodeproj"> | ||
| 62 | + </BuildableReference> | ||
| 63 | + </BuildableProductRunnable> | ||
| 64 | + <AdditionalOptions> | ||
| 65 | + </AdditionalOptions> | ||
| 66 | + </LaunchAction> | ||
| 67 | + <ProfileAction | ||
| 68 | + buildConfiguration = "Profile" | ||
| 69 | + shouldUseLaunchSchemeArgsEnv = "YES" | ||
| 70 | + savedToolIdentifier = "" | ||
| 71 | + useCustomWorkingDirectory = "NO" | ||
| 72 | + debugDocumentVersioning = "YES"> | ||
| 73 | + <BuildableProductRunnable | ||
| 74 | + runnableDebuggingMode = "0"> | ||
| 75 | + <BuildableReference | ||
| 76 | + BuildableIdentifier = "primary" | ||
| 77 | + BlueprintIdentifier = "97C146ED1CF9000F007C117D" | ||
| 78 | + BuildableName = "Runner.app" | ||
| 79 | + BlueprintName = "Runner" | ||
| 80 | + ReferencedContainer = "container:Runner.xcodeproj"> | ||
| 81 | + </BuildableReference> | ||
| 82 | + </BuildableProductRunnable> | ||
| 83 | + </ProfileAction> | ||
| 84 | + <AnalyzeAction | ||
| 85 | + buildConfiguration = "Debug"> | ||
| 86 | + </AnalyzeAction> | ||
| 87 | + <ArchiveAction | ||
| 88 | + buildConfiguration = "Release" | ||
| 89 | + revealArchiveInOrganizer = "YES"> | ||
| 90 | + </ArchiveAction> | ||
| 91 | +</Scheme> |
example/ios/Runner/AppDelegate.h
0 → 100644
example/ios/Runner/AppDelegate.m
0 → 100644
| 1 | +#include "AppDelegate.h" | ||
| 2 | +#include "GeneratedPluginRegistrant.h" | ||
| 3 | + | ||
| 4 | +@implementation AppDelegate | ||
| 5 | + | ||
| 6 | +- (BOOL)application:(UIApplication *)application | ||
| 7 | + didFinishLaunchingWithOptions:(NSDictionary *)launchOptions { | ||
| 8 | + [GeneratedPluginRegistrant registerWithRegistry:self]; | ||
| 9 | + // Override point for customization after application launch. | ||
| 10 | + return [super application:application didFinishLaunchingWithOptions:launchOptions]; | ||
| 11 | +} | ||
| 12 | + | ||
| 13 | +@end |
| 1 | +{ | ||
| 2 | + "images" : [ | ||
| 3 | + { | ||
| 4 | + "size" : "20x20", | ||
| 5 | + "idiom" : "iphone", | ||
| 6 | + "filename" : "Icon-App-20x20@2x.png", | ||
| 7 | + "scale" : "2x" | ||
| 8 | + }, | ||
| 9 | + { | ||
| 10 | + "size" : "20x20", | ||
| 11 | + "idiom" : "iphone", | ||
| 12 | + "filename" : "Icon-App-20x20@3x.png", | ||
| 13 | + "scale" : "3x" | ||
| 14 | + }, | ||
| 15 | + { | ||
| 16 | + "size" : "29x29", | ||
| 17 | + "idiom" : "iphone", | ||
| 18 | + "filename" : "Icon-App-29x29@1x.png", | ||
| 19 | + "scale" : "1x" | ||
| 20 | + }, | ||
| 21 | + { | ||
| 22 | + "size" : "29x29", | ||
| 23 | + "idiom" : "iphone", | ||
| 24 | + "filename" : "Icon-App-29x29@2x.png", | ||
| 25 | + "scale" : "2x" | ||
| 26 | + }, | ||
| 27 | + { | ||
| 28 | + "size" : "29x29", | ||
| 29 | + "idiom" : "iphone", | ||
| 30 | + "filename" : "Icon-App-29x29@3x.png", | ||
| 31 | + "scale" : "3x" | ||
| 32 | + }, | ||
| 33 | + { | ||
| 34 | + "size" : "40x40", | ||
| 35 | + "idiom" : "iphone", | ||
| 36 | + "filename" : "Icon-App-40x40@2x.png", | ||
| 37 | + "scale" : "2x" | ||
| 38 | + }, | ||
| 39 | + { | ||
| 40 | + "size" : "40x40", | ||
| 41 | + "idiom" : "iphone", | ||
| 42 | + "filename" : "Icon-App-40x40@3x.png", | ||
| 43 | + "scale" : "3x" | ||
| 44 | + }, | ||
| 45 | + { | ||
| 46 | + "size" : "60x60", | ||
| 47 | + "idiom" : "iphone", | ||
| 48 | + "filename" : "Icon-App-60x60@2x.png", | ||
| 49 | + "scale" : "2x" | ||
| 50 | + }, | ||
| 51 | + { | ||
| 52 | + "size" : "60x60", | ||
| 53 | + "idiom" : "iphone", | ||
| 54 | + "filename" : "Icon-App-60x60@3x.png", | ||
| 55 | + "scale" : "3x" | ||
| 56 | + }, | ||
| 57 | + { | ||
| 58 | + "size" : "20x20", | ||
| 59 | + "idiom" : "ipad", | ||
| 60 | + "filename" : "Icon-App-20x20@1x.png", | ||
| 61 | + "scale" : "1x" | ||
| 62 | + }, | ||
| 63 | + { | ||
| 64 | + "size" : "20x20", | ||
| 65 | + "idiom" : "ipad", | ||
| 66 | + "filename" : "Icon-App-20x20@2x.png", | ||
| 67 | + "scale" : "2x" | ||
| 68 | + }, | ||
| 69 | + { | ||
| 70 | + "size" : "29x29", | ||
| 71 | + "idiom" : "ipad", | ||
| 72 | + "filename" : "Icon-App-29x29@1x.png", | ||
| 73 | + "scale" : "1x" | ||
| 74 | + }, | ||
| 75 | + { | ||
| 76 | + "size" : "29x29", | ||
| 77 | + "idiom" : "ipad", | ||
| 78 | + "filename" : "Icon-App-29x29@2x.png", | ||
| 79 | + "scale" : "2x" | ||
| 80 | + }, | ||
| 81 | + { | ||
| 82 | + "size" : "40x40", | ||
| 83 | + "idiom" : "ipad", | ||
| 84 | + "filename" : "Icon-App-40x40@1x.png", | ||
| 85 | + "scale" : "1x" | ||
| 86 | + }, | ||
| 87 | + { | ||
| 88 | + "size" : "40x40", | ||
| 89 | + "idiom" : "ipad", | ||
| 90 | + "filename" : "Icon-App-40x40@2x.png", | ||
| 91 | + "scale" : "2x" | ||
| 92 | + }, | ||
| 93 | + { | ||
| 94 | + "size" : "76x76", | ||
| 95 | + "idiom" : "ipad", | ||
| 96 | + "filename" : "Icon-App-76x76@1x.png", | ||
| 97 | + "scale" : "1x" | ||
| 98 | + }, | ||
| 99 | + { | ||
| 100 | + "size" : "76x76", | ||
| 101 | + "idiom" : "ipad", | ||
| 102 | + "filename" : "Icon-App-76x76@2x.png", | ||
| 103 | + "scale" : "2x" | ||
| 104 | + }, | ||
| 105 | + { | ||
| 106 | + "size" : "83.5x83.5", | ||
| 107 | + "idiom" : "ipad", | ||
| 108 | + "filename" : "Icon-App-83.5x83.5@2x.png", | ||
| 109 | + "scale" : "2x" | ||
| 110 | + }, | ||
| 111 | + { | ||
| 112 | + "size" : "1024x1024", | ||
| 113 | + "idiom" : "ios-marketing", | ||
| 114 | + "filename" : "Icon-App-1024x1024@1x.png", | ||
| 115 | + "scale" : "1x" | ||
| 116 | + } | ||
| 117 | + ], | ||
| 118 | + "info" : { | ||
| 119 | + "version" : 1, | ||
| 120 | + "author" : "xcode" | ||
| 121 | + } | ||
| 122 | +} |
564 Bytes
1.25 KB
1.55 KB
1.68 KB
1.88 KB
1.25 KB
1.85 KB
3.74 KB
1.84 KB
3.22 KB
| 1 | +{ | ||
| 2 | + "images" : [ | ||
| 3 | + { | ||
| 4 | + "idiom" : "universal", | ||
| 5 | + "filename" : "LaunchImage.png", | ||
| 6 | + "scale" : "1x" | ||
| 7 | + }, | ||
| 8 | + { | ||
| 9 | + "idiom" : "universal", | ||
| 10 | + "filename" : "LaunchImage@2x.png", | ||
| 11 | + "scale" : "2x" | ||
| 12 | + }, | ||
| 13 | + { | ||
| 14 | + "idiom" : "universal", | ||
| 15 | + "filename" : "LaunchImage@3x.png", | ||
| 16 | + "scale" : "3x" | ||
| 17 | + } | ||
| 18 | + ], | ||
| 19 | + "info" : { | ||
| 20 | + "version" : 1, | ||
| 21 | + "author" : "xcode" | ||
| 22 | + } | ||
| 23 | +} |
68 Bytes
68 Bytes
68 Bytes
| 1 | +# Launch Screen Assets | ||
| 2 | + | ||
| 3 | +You can customize the launch screen with your own desired assets by replacing the image files in this directory. | ||
| 4 | + | ||
| 5 | +You can also do it by opening your Flutter project's Xcode project with `open ios/Runner.xcworkspace`, selecting `Runner/Assets.xcassets` in the Project Navigator and dropping in the desired images. |
| 1 | +<?xml version="1.0" encoding="UTF-8" standalone="no"?> | ||
| 2 | +<document type="com.apple.InterfaceBuilder3.CocoaTouch.Storyboard.XIB" version="3.0" toolsVersion="12121" systemVersion="16G29" targetRuntime="iOS.CocoaTouch" propertyAccessControl="none" useAutolayout="YES" launchScreen="YES" colorMatched="YES" initialViewController="01J-lp-oVM"> | ||
| 3 | + <dependencies> | ||
| 4 | + <deployment identifier="iOS"/> | ||
| 5 | + <plugIn identifier="com.apple.InterfaceBuilder.IBCocoaTouchPlugin" version="12089"/> | ||
| 6 | + </dependencies> | ||
| 7 | + <scenes> | ||
| 8 | + <!--View Controller--> | ||
| 9 | + <scene sceneID="EHf-IW-A2E"> | ||
| 10 | + <objects> | ||
| 11 | + <viewController id="01J-lp-oVM" sceneMemberID="viewController"> | ||
| 12 | + <layoutGuides> | ||
| 13 | + <viewControllerLayoutGuide type="top" id="Ydg-fD-yQy"/> | ||
| 14 | + <viewControllerLayoutGuide type="bottom" id="xbc-2k-c8Z"/> | ||
| 15 | + </layoutGuides> | ||
| 16 | + <view key="view" contentMode="scaleToFill" id="Ze5-6b-2t3"> | ||
| 17 | + <autoresizingMask key="autoresizingMask" widthSizable="YES" heightSizable="YES"/> | ||
| 18 | + <subviews> | ||
| 19 | + <imageView opaque="NO" clipsSubviews="YES" multipleTouchEnabled="YES" contentMode="center" image="LaunchImage" translatesAutoresizingMaskIntoConstraints="NO" id="YRO-k0-Ey4"> | ||
| 20 | + </imageView> | ||
| 21 | + </subviews> | ||
| 22 | + <color key="backgroundColor" red="1" green="1" blue="1" alpha="1" colorSpace="custom" customColorSpace="sRGB"/> | ||
| 23 | + <constraints> | ||
| 24 | + <constraint firstItem="YRO-k0-Ey4" firstAttribute="centerX" secondItem="Ze5-6b-2t3" secondAttribute="centerX" id="1a2-6s-vTC"/> | ||
| 25 | + <constraint firstItem="YRO-k0-Ey4" firstAttribute="centerY" secondItem="Ze5-6b-2t3" secondAttribute="centerY" id="4X2-HB-R7a"/> | ||
| 26 | + </constraints> | ||
| 27 | + </view> | ||
| 28 | + </viewController> | ||
| 29 | + <placeholder placeholderIdentifier="IBFirstResponder" id="iYj-Kq-Ea1" userLabel="First Responder" sceneMemberID="firstResponder"/> | ||
| 30 | + </objects> | ||
| 31 | + <point key="canvasLocation" x="53" y="375"/> | ||
| 32 | + </scene> | ||
| 33 | + </scenes> | ||
| 34 | + <resources> | ||
| 35 | + <image name="LaunchImage" width="168" height="185"/> | ||
| 36 | + </resources> | ||
| 37 | +</document> |
| 1 | +<?xml version="1.0" encoding="UTF-8" standalone="no"?> | ||
| 2 | +<document type="com.apple.InterfaceBuilder3.CocoaTouch.Storyboard.XIB" version="3.0" toolsVersion="10117" systemVersion="15F34" targetRuntime="iOS.CocoaTouch" propertyAccessControl="none" useAutolayout="YES" useTraitCollections="YES" initialViewController="BYZ-38-t0r"> | ||
| 3 | + <dependencies> | ||
| 4 | + <deployment identifier="iOS"/> | ||
| 5 | + <plugIn identifier="com.apple.InterfaceBuilder.IBCocoaTouchPlugin" version="10085"/> | ||
| 6 | + </dependencies> | ||
| 7 | + <scenes> | ||
| 8 | + <!--Flutter View Controller--> | ||
| 9 | + <scene sceneID="tne-QT-ifu"> | ||
| 10 | + <objects> | ||
| 11 | + <viewController id="BYZ-38-t0r" customClass="FlutterViewController" sceneMemberID="viewController"> | ||
| 12 | + <layoutGuides> | ||
| 13 | + <viewControllerLayoutGuide type="top" id="y3c-jy-aDJ"/> | ||
| 14 | + <viewControllerLayoutGuide type="bottom" id="wfy-db-euE"/> | ||
| 15 | + </layoutGuides> | ||
| 16 | + <view key="view" contentMode="scaleToFill" id="8bC-Xf-vdC"> | ||
| 17 | + <rect key="frame" x="0.0" y="0.0" width="600" height="600"/> | ||
| 18 | + <autoresizingMask key="autoresizingMask" widthSizable="YES" heightSizable="YES"/> | ||
| 19 | + <color key="backgroundColor" white="1" alpha="1" colorSpace="custom" customColorSpace="calibratedWhite"/> | ||
| 20 | + </view> | ||
| 21 | + </viewController> | ||
| 22 | + <placeholder placeholderIdentifier="IBFirstResponder" id="dkx-z0-nzr" sceneMemberID="firstResponder"/> | ||
| 23 | + </objects> | ||
| 24 | + </scene> | ||
| 25 | + </scenes> | ||
| 26 | +</document> |
example/ios/Runner/Info.plist
0 → 100644
| 1 | +<?xml version="1.0" encoding="UTF-8"?> | ||
| 2 | +<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd"> | ||
| 3 | +<plist version="1.0"> | ||
| 4 | +<dict> | ||
| 5 | + <key>CFBundleDevelopmentRegion</key> | ||
| 6 | + <string>$(DEVELOPMENT_LANGUAGE)</string> | ||
| 7 | + <key>CFBundleExecutable</key> | ||
| 8 | + <string>$(EXECUTABLE_NAME)</string> | ||
| 9 | + <key>CFBundleIdentifier</key> | ||
| 10 | + <string>$(PRODUCT_BUNDLE_IDENTIFIER)</string> | ||
| 11 | + <key>CFBundleInfoDictionaryVersion</key> | ||
| 12 | + <string>6.0</string> | ||
| 13 | + <key>CFBundleName</key> | ||
| 14 | + <string>wakelock_example</string> | ||
| 15 | + <key>CFBundlePackageType</key> | ||
| 16 | + <string>APPL</string> | ||
| 17 | + <key>CFBundleShortVersionString</key> | ||
| 18 | + <string>$(FLUTTER_BUILD_NAME)</string> | ||
| 19 | + <key>CFBundleSignature</key> | ||
| 20 | + <string>????</string> | ||
| 21 | + <key>CFBundleVersion</key> | ||
| 22 | + <string>$(FLUTTER_BUILD_NUMBER)</string> | ||
| 23 | + <key>LSRequiresIPhoneOS</key> | ||
| 24 | + <true/> | ||
| 25 | + <key>UILaunchStoryboardName</key> | ||
| 26 | + <string>LaunchScreen</string> | ||
| 27 | + <key>UIMainStoryboardFile</key> | ||
| 28 | + <string>Main</string> | ||
| 29 | + <key>UISupportedInterfaceOrientations</key> | ||
| 30 | + <array> | ||
| 31 | + <string>UIInterfaceOrientationPortrait</string> | ||
| 32 | + <string>UIInterfaceOrientationLandscapeLeft</string> | ||
| 33 | + <string>UIInterfaceOrientationLandscapeRight</string> | ||
| 34 | + </array> | ||
| 35 | + <key>UISupportedInterfaceOrientations~ipad</key> | ||
| 36 | + <array> | ||
| 37 | + <string>UIInterfaceOrientationPortrait</string> | ||
| 38 | + <string>UIInterfaceOrientationPortraitUpsideDown</string> | ||
| 39 | + <string>UIInterfaceOrientationLandscapeLeft</string> | ||
| 40 | + <string>UIInterfaceOrientationLandscapeRight</string> | ||
| 41 | + </array> | ||
| 42 | + <key>UIViewControllerBasedStatusBarAppearance</key> | ||
| 43 | + <false/> | ||
| 44 | +</dict> | ||
| 45 | +</plist> |
example/ios/Runner/main.m
0 → 100644
example/lib/main.dart
0 → 100644
| 1 | +import 'package:flutter/material.dart'; | ||
| 2 | +import 'package:wakelock/wakelock.dart'; | ||
| 3 | + | ||
| 4 | +void main() => runApp(MyApp()); | ||
| 5 | + | ||
| 6 | +/// The wakelock implementation is located inside the [FlatButton.onPressed] functions and a [FutureBuilder]. | ||
| 7 | +/// The [FlatButton]'s and the [FutureBuilder] sit inside the [Column] that is a child of the [Scaffold] in [_MyAppState]. | ||
| 8 | +class MyApp extends StatefulWidget { | ||
| 9 | + const MyApp({Key key}) : super(key: key); | ||
| 10 | + | ||
| 11 | + @override | ||
| 12 | + _MyAppState createState() => _MyAppState(); | ||
| 13 | +} | ||
| 14 | + | ||
| 15 | +class _MyAppState extends State<MyApp> { | ||
| 16 | + @override | ||
| 17 | + Widget build(BuildContext context) => MaterialApp( | ||
| 18 | + home: Scaffold( | ||
| 19 | + body: Center( | ||
| 20 | + child: Column(mainAxisAlignment: MainAxisAlignment.spaceEvenly, children: <Widget>[ | ||
| 21 | + FlatButton( | ||
| 22 | + child: const Text('enable wakelock'), | ||
| 23 | + onPressed: () { | ||
| 24 | + // The following code will enable the wakelock on Android or iOS using the wakelock plugin. | ||
| 25 | + setState(() { | ||
| 26 | + Wakelock.enableWakelock(); | ||
| 27 | + }); | ||
| 28 | + }, | ||
| 29 | + ), | ||
| 30 | + FlatButton( | ||
| 31 | + child: const Text('disable wakelock'), | ||
| 32 | + onPressed: () { | ||
| 33 | + // The following code will disable the wakelock on Android or iOS using the wakelock plugin. | ||
| 34 | + setState(() { | ||
| 35 | + Wakelock.disableWakelock(); | ||
| 36 | + }); | ||
| 37 | + }, | ||
| 38 | + ), | ||
| 39 | + FutureBuilder( | ||
| 40 | + future: Wakelock.isWakelockEnabled, | ||
| 41 | + builder: (context, AsyncSnapshot<bool> snapshot) { | ||
| 42 | + // The use of FutureBuilder is necessary here to await the bool value from isWakelockEnabled. | ||
| 43 | + if (!snapshot.hasData) return Container(); // The Future is retrieved so fast that you will not be able to see any loading indicator. | ||
| 44 | + return Text('wakelock is currently ${snapshot.data ? 'enabled' : 'disabled'}'); | ||
| 45 | + }, | ||
| 46 | + ) | ||
| 47 | + ])))); | ||
| 48 | +} |
example/pubspec.lock
0 → 100644
| 1 | +# Generated by pub | ||
| 2 | +# See https://dart.dev/tools/pub/glossary#lockfile | ||
| 3 | +packages: | ||
| 4 | + async: | ||
| 5 | + dependency: transitive | ||
| 6 | + description: | ||
| 7 | + name: async | ||
| 8 | + url: "https://pub.dartlang.org" | ||
| 9 | + source: hosted | ||
| 10 | + version: "2.2.0" | ||
| 11 | + boolean_selector: | ||
| 12 | + dependency: transitive | ||
| 13 | + description: | ||
| 14 | + name: boolean_selector | ||
| 15 | + url: "https://pub.dartlang.org" | ||
| 16 | + source: hosted | ||
| 17 | + version: "1.0.5" | ||
| 18 | + charcode: | ||
| 19 | + dependency: transitive | ||
| 20 | + description: | ||
| 21 | + name: charcode | ||
| 22 | + url: "https://pub.dartlang.org" | ||
| 23 | + source: hosted | ||
| 24 | + version: "1.1.2" | ||
| 25 | + collection: | ||
| 26 | + dependency: transitive | ||
| 27 | + description: | ||
| 28 | + name: collection | ||
| 29 | + url: "https://pub.dartlang.org" | ||
| 30 | + source: hosted | ||
| 31 | + version: "1.14.11" | ||
| 32 | + cupertino_icons: | ||
| 33 | + dependency: "direct main" | ||
| 34 | + description: | ||
| 35 | + name: cupertino_icons | ||
| 36 | + url: "https://pub.dartlang.org" | ||
| 37 | + source: hosted | ||
| 38 | + version: "0.1.2" | ||
| 39 | + flutter: | ||
| 40 | + dependency: "direct main" | ||
| 41 | + description: flutter | ||
| 42 | + source: sdk | ||
| 43 | + version: "0.0.0" | ||
| 44 | + flutter_test: | ||
| 45 | + dependency: "direct dev" | ||
| 46 | + description: flutter | ||
| 47 | + source: sdk | ||
| 48 | + version: "0.0.0" | ||
| 49 | + matcher: | ||
| 50 | + dependency: transitive | ||
| 51 | + description: | ||
| 52 | + name: matcher | ||
| 53 | + url: "https://pub.dartlang.org" | ||
| 54 | + source: hosted | ||
| 55 | + version: "0.12.5" | ||
| 56 | + meta: | ||
| 57 | + dependency: transitive | ||
| 58 | + description: | ||
| 59 | + name: meta | ||
| 60 | + url: "https://pub.dartlang.org" | ||
| 61 | + source: hosted | ||
| 62 | + version: "1.1.6" | ||
| 63 | + path: | ||
| 64 | + dependency: transitive | ||
| 65 | + description: | ||
| 66 | + name: path | ||
| 67 | + url: "https://pub.dartlang.org" | ||
| 68 | + source: hosted | ||
| 69 | + version: "1.6.2" | ||
| 70 | + pedantic: | ||
| 71 | + dependency: transitive | ||
| 72 | + description: | ||
| 73 | + name: pedantic | ||
| 74 | + url: "https://pub.dartlang.org" | ||
| 75 | + source: hosted | ||
| 76 | + version: "1.8.0+1" | ||
| 77 | + quiver: | ||
| 78 | + dependency: transitive | ||
| 79 | + description: | ||
| 80 | + name: quiver | ||
| 81 | + url: "https://pub.dartlang.org" | ||
| 82 | + source: hosted | ||
| 83 | + version: "2.0.3" | ||
| 84 | + sky_engine: | ||
| 85 | + dependency: transitive | ||
| 86 | + description: flutter | ||
| 87 | + source: sdk | ||
| 88 | + version: "0.0.99" | ||
| 89 | + source_span: | ||
| 90 | + dependency: transitive | ||
| 91 | + description: | ||
| 92 | + name: source_span | ||
| 93 | + url: "https://pub.dartlang.org" | ||
| 94 | + source: hosted | ||
| 95 | + version: "1.5.5" | ||
| 96 | + stack_trace: | ||
| 97 | + dependency: transitive | ||
| 98 | + description: | ||
| 99 | + name: stack_trace | ||
| 100 | + url: "https://pub.dartlang.org" | ||
| 101 | + source: hosted | ||
| 102 | + version: "1.9.3" | ||
| 103 | + stream_channel: | ||
| 104 | + dependency: transitive | ||
| 105 | + description: | ||
| 106 | + name: stream_channel | ||
| 107 | + url: "https://pub.dartlang.org" | ||
| 108 | + source: hosted | ||
| 109 | + version: "2.0.0" | ||
| 110 | + string_scanner: | ||
| 111 | + dependency: transitive | ||
| 112 | + description: | ||
| 113 | + name: string_scanner | ||
| 114 | + url: "https://pub.dartlang.org" | ||
| 115 | + source: hosted | ||
| 116 | + version: "1.0.4" | ||
| 117 | + term_glyph: | ||
| 118 | + dependency: transitive | ||
| 119 | + description: | ||
| 120 | + name: term_glyph | ||
| 121 | + url: "https://pub.dartlang.org" | ||
| 122 | + source: hosted | ||
| 123 | + version: "1.1.0" | ||
| 124 | + test_api: | ||
| 125 | + dependency: transitive | ||
| 126 | + description: | ||
| 127 | + name: test_api | ||
| 128 | + url: "https://pub.dartlang.org" | ||
| 129 | + source: hosted | ||
| 130 | + version: "0.2.5" | ||
| 131 | + typed_data: | ||
| 132 | + dependency: transitive | ||
| 133 | + description: | ||
| 134 | + name: typed_data | ||
| 135 | + url: "https://pub.dartlang.org" | ||
| 136 | + source: hosted | ||
| 137 | + version: "1.1.6" | ||
| 138 | + vector_math: | ||
| 139 | + dependency: transitive | ||
| 140 | + description: | ||
| 141 | + name: vector_math | ||
| 142 | + url: "https://pub.dartlang.org" | ||
| 143 | + source: hosted | ||
| 144 | + version: "2.0.8" | ||
| 145 | + wakelock: | ||
| 146 | + dependency: "direct dev" | ||
| 147 | + description: | ||
| 148 | + path: ".." | ||
| 149 | + relative: true | ||
| 150 | + source: path | ||
| 151 | + version: "0.0.1" | ||
| 152 | +sdks: | ||
| 153 | + dart: ">=2.2.2 <3.0.0" |
example/pubspec.yaml
0 → 100644
| 1 | +name: wakelock_example | ||
| 2 | +description: Demonstrates how to use the wakelock plugin. | ||
| 3 | +publish_to: 'none' | ||
| 4 | + | ||
| 5 | +environment: | ||
| 6 | + sdk: ">=2.1.0 <3.0.0" | ||
| 7 | + | ||
| 8 | +dependencies: | ||
| 9 | + flutter: | ||
| 10 | + sdk: flutter | ||
| 11 | + | ||
| 12 | + # The following adds the Cupertino Icons font to your application. | ||
| 13 | + # Use with the CupertinoIcons class for iOS style icons. | ||
| 14 | + cupertino_icons: ^0.1.2 | ||
| 15 | + | ||
| 16 | +dev_dependencies: | ||
| 17 | + flutter_test: | ||
| 18 | + sdk: flutter | ||
| 19 | + | ||
| 20 | + wakelock: | ||
| 21 | + path: ../ | ||
| 22 | + | ||
| 23 | +# For information on the generic Dart part of this file, see the | ||
| 24 | +# following page: https://dart.dev/tools/pub/pubspec | ||
| 25 | + | ||
| 26 | +# The following section is specific to Flutter. | ||
| 27 | +flutter: | ||
| 28 | + | ||
| 29 | + # The following line ensures that the Material Icons font is | ||
| 30 | + # included with your application, so that you can use the icons in | ||
| 31 | + # the material Icons class. | ||
| 32 | + uses-material-design: true | ||
| 33 | + | ||
| 34 | + # To add assets to your application, add an assets section, like this: | ||
| 35 | + # assets: | ||
| 36 | + # - images/a_dot_burr.jpeg | ||
| 37 | + # - images/a_dot_ham.jpeg | ||
| 38 | + | ||
| 39 | + # An image asset can refer to one or more resolution-specific "variants", see | ||
| 40 | + # https://flutter.dev/assets-and-images/#resolution-aware. | ||
| 41 | + | ||
| 42 | + # For details regarding adding assets from package dependencies, see | ||
| 43 | + # https://flutter.dev/assets-and-images/#from-packages | ||
| 44 | + | ||
| 45 | + # To add custom fonts to your application, add a fonts section here, | ||
| 46 | + # in this "flutter" section. Each entry in this list should have a | ||
| 47 | + # "family" key with the font family name, and a "fonts" key with a | ||
| 48 | + # list giving the asset and other descriptors for the font. For | ||
| 49 | + # example: | ||
| 50 | + # fonts: | ||
| 51 | + # - family: Schyler | ||
| 52 | + # fonts: | ||
| 53 | + # - asset: fonts/Schyler-Regular.ttf | ||
| 54 | + # - asset: fonts/Schyler-Italic.ttf | ||
| 55 | + # style: italic | ||
| 56 | + # - family: Trajan Pro | ||
| 57 | + # fonts: | ||
| 58 | + # - asset: fonts/TrajanPro.ttf | ||
| 59 | + # - asset: fonts/TrajanPro_Bold.ttf | ||
| 60 | + # weight: 700 | ||
| 61 | + # | ||
| 62 | + # For details regarding fonts from package dependencies, | ||
| 63 | + # see https://flutter.dev/custom-fonts/#from-packages |
ios/.gitignore
0 → 100644
| 1 | +.idea/ | ||
| 2 | +.vagrant/ | ||
| 3 | +.sconsign.dblite | ||
| 4 | +.svn/ | ||
| 5 | + | ||
| 6 | +.DS_Store | ||
| 7 | +*.swp | ||
| 8 | +profile | ||
| 9 | + | ||
| 10 | +DerivedData/ | ||
| 11 | +build/ | ||
| 12 | +GeneratedPluginRegistrant.h | ||
| 13 | +GeneratedPluginRegistrant.m | ||
| 14 | + | ||
| 15 | +.generated/ | ||
| 16 | + | ||
| 17 | +*.pbxuser | ||
| 18 | +*.mode1v3 | ||
| 19 | +*.mode2v3 | ||
| 20 | +*.perspectivev3 | ||
| 21 | + | ||
| 22 | +!default.pbxuser | ||
| 23 | +!default.mode1v3 | ||
| 24 | +!default.mode2v3 | ||
| 25 | +!default.perspectivev3 | ||
| 26 | + | ||
| 27 | +xcuserdata | ||
| 28 | + | ||
| 29 | +*.moved-aside | ||
| 30 | + | ||
| 31 | +*.pyc | ||
| 32 | +*sync/ | ||
| 33 | +Icon? | ||
| 34 | +.tags* | ||
| 35 | + | ||
| 36 | +/Flutter/Generated.xcconfig |
ios/Assets/.gitkeep
0 → 100644
ios/Classes/WakelockPlugin.h
0 → 100644
ios/Classes/WakelockPlugin.m
0 → 100644
| 1 | +#import "WakelockPlugin.h" | ||
| 2 | + | ||
| 3 | +@implementation WakelockPlugin | ||
| 4 | ++ (void)registerWithRegistrar:(NSObject<FlutterPluginRegistrar>*)registrar { | ||
| 5 | + FlutterMethodChannel* channel = [FlutterMethodChannel | ||
| 6 | + methodChannelWithName:@"wakelock" | ||
| 7 | + binaryMessenger:[registrar messenger]]; | ||
| 8 | + WakelockPlugin* instance = [[WakelockPlugin alloc] init]; | ||
| 9 | + [registrar addMethodCallDelegate:instance channel:channel]; | ||
| 10 | +} | ||
| 11 | + | ||
| 12 | +- (void)handleMethodCall:(FlutterMethodCall*)call result:(FlutterResult)result { | ||
| 13 | + if ([@"toggleWakelock" isEqualToString:call.method]) { | ||
| 14 | + NSNumber *enable = call.arguments[@"enable"]; | ||
| 15 | + [[UIApplication sharedApplication] setIdleTimerDisabled:enable.boolValue]; | ||
| 16 | + result(nil); | ||
| 17 | + } else if ([@"isWakelockEnabled" isEqualToString:call.method]) { | ||
| 18 | + bool enabled = [[UIApplication sharedApplication] isIdleTimerDisabled]; | ||
| 19 | + result([NSNumber numberWithBool:enabled]); | ||
| 20 | + } else { | ||
| 21 | + result(FlutterMethodNotImplemented); | ||
| 22 | + } | ||
| 23 | +} | ||
| 24 | + | ||
| 25 | +@end |
ios/wakelock.podspec
0 → 100644
| 1 | +# | ||
| 2 | +# To learn more about a Podspec see http://guides.cocoapods.org/syntax/podspec.html | ||
| 3 | +# | ||
| 4 | +Pod::Spec.new do |s| | ||
| 5 | + s.name = 'wakelock' | ||
| 6 | + s.version = '0.0.1' | ||
| 7 | + s.summary = 'A new flutter plugin project.' | ||
| 8 | + s.description = <<-DESC | ||
| 9 | +A new flutter plugin project. | ||
| 10 | + DESC | ||
| 11 | + s.homepage = 'http://example.com' | ||
| 12 | + s.license = { :file => '../LICENSE' } | ||
| 13 | + s.author = { 'Your Company' => 'email@example.com' } | ||
| 14 | + s.source = { :path => '.' } | ||
| 15 | + s.source_files = 'Classes/**/*' | ||
| 16 | + s.public_header_files = 'Classes/**/*.h' | ||
| 17 | + s.dependency 'Flutter' | ||
| 18 | + | ||
| 19 | + s.ios.deployment_target = '8.0' | ||
| 20 | +end | ||
| 21 | + |
lib/wakelock.dart
0 → 100644
| 1 | +import 'dart:async'; | ||
| 2 | + | ||
| 3 | +import 'package:flutter/services.dart'; | ||
| 4 | + | ||
| 5 | +/// To enable the wakelock, you can use [Wakelock.enableWakelock] and to disable it, | ||
| 6 | +/// you can call [Wakelock.disableWakelock]. | ||
| 7 | +/// You do not need to worry about making redundant calls, e.g. calling [Wakelock.enableWakelock] | ||
| 8 | +/// when the wakelock is already enabled as the plugin handles this for you. | ||
| 9 | +/// If you want the flexibility to pass a [bool] to control whether the wakelock should be | ||
| 10 | +/// enabled or disabled, you can use [Wakelock.toggleWakelock]. | ||
| 11 | +/// | ||
| 12 | +/// The [Wakelock.isWakelockEnabled] function allows you to retrieve the current wakelock | ||
| 13 | +/// status from Android or iOS. | ||
| 14 | +class Wakelock { | ||
| 15 | + static const MethodChannel _channel = const MethodChannel('wakelock'); | ||
| 16 | + | ||
| 17 | + /// This can simply be called using `Wakelock.enableWakelock()` and does not return anything. | ||
| 18 | + /// You can await the [Future] to wait for the operation to complete. | ||
| 19 | + static Future<void> enableWakelock() => _channel.invokeMethod('toggleWakelock', {'enable': true}); | ||
| 20 | + | ||
| 21 | + /// This can simply be called using `Wakelock.disableWakelock()` and does not return anything. | ||
| 22 | + /// You can await the [Future] to wait for the operation to complete. | ||
| 23 | + static Future<void> disableWakelock() => _channel.invokeMethod('toggleWakelock', {'enable': false}); | ||
| 24 | + | ||
| 25 | + /// You can simply use this function to toggle the wakelock using a [bool] value. | ||
| 26 | + /// ```dart | ||
| 27 | + /// bool enable = true; | ||
| 28 | + /// Wakelock.toggleWakelock(enable); | ||
| 29 | + /// ``` | ||
| 30 | + /// You can await the [Future] to wait for the operation to complete. | ||
| 31 | + static Future<void> toggleWakelock(bool enable) => _channel.invokeMethod('toggleWakelock', {'enable': enable}); | ||
| 32 | + | ||
| 33 | + /// If you want to retrieve the current wakelock status, you will have to call [Wakelock.isWakelockEnabled] | ||
| 34 | + /// and await its result: `bool isWakelockEnabled = await Wakelock.isWakelockEnabled()` | ||
| 35 | + static Future<bool> get isWakelockEnabled => _channel.invokeMethod('isWakelockEnabled'); | ||
| 36 | +} |
pubspec.lock
0 → 100644
| 1 | +# Generated by pub | ||
| 2 | +# See https://dart.dev/tools/pub/glossary#lockfile | ||
| 3 | +packages: | ||
| 4 | + async: | ||
| 5 | + dependency: transitive | ||
| 6 | + description: | ||
| 7 | + name: async | ||
| 8 | + url: "https://pub.dartlang.org" | ||
| 9 | + source: hosted | ||
| 10 | + version: "2.2.0" | ||
| 11 | + boolean_selector: | ||
| 12 | + dependency: transitive | ||
| 13 | + description: | ||
| 14 | + name: boolean_selector | ||
| 15 | + url: "https://pub.dartlang.org" | ||
| 16 | + source: hosted | ||
| 17 | + version: "1.0.5" | ||
| 18 | + charcode: | ||
| 19 | + dependency: transitive | ||
| 20 | + description: | ||
| 21 | + name: charcode | ||
| 22 | + url: "https://pub.dartlang.org" | ||
| 23 | + source: hosted | ||
| 24 | + version: "1.1.2" | ||
| 25 | + collection: | ||
| 26 | + dependency: transitive | ||
| 27 | + description: | ||
| 28 | + name: collection | ||
| 29 | + url: "https://pub.dartlang.org" | ||
| 30 | + source: hosted | ||
| 31 | + version: "1.14.11" | ||
| 32 | + flutter: | ||
| 33 | + dependency: "direct main" | ||
| 34 | + description: flutter | ||
| 35 | + source: sdk | ||
| 36 | + version: "0.0.0" | ||
| 37 | + flutter_test: | ||
| 38 | + dependency: "direct dev" | ||
| 39 | + description: flutter | ||
| 40 | + source: sdk | ||
| 41 | + version: "0.0.0" | ||
| 42 | + matcher: | ||
| 43 | + dependency: transitive | ||
| 44 | + description: | ||
| 45 | + name: matcher | ||
| 46 | + url: "https://pub.dartlang.org" | ||
| 47 | + source: hosted | ||
| 48 | + version: "0.12.5" | ||
| 49 | + meta: | ||
| 50 | + dependency: transitive | ||
| 51 | + description: | ||
| 52 | + name: meta | ||
| 53 | + url: "https://pub.dartlang.org" | ||
| 54 | + source: hosted | ||
| 55 | + version: "1.1.6" | ||
| 56 | + path: | ||
| 57 | + dependency: transitive | ||
| 58 | + description: | ||
| 59 | + name: path | ||
| 60 | + url: "https://pub.dartlang.org" | ||
| 61 | + source: hosted | ||
| 62 | + version: "1.6.2" | ||
| 63 | + pedantic: | ||
| 64 | + dependency: transitive | ||
| 65 | + description: | ||
| 66 | + name: pedantic | ||
| 67 | + url: "https://pub.dartlang.org" | ||
| 68 | + source: hosted | ||
| 69 | + version: "1.8.0+1" | ||
| 70 | + quiver: | ||
| 71 | + dependency: transitive | ||
| 72 | + description: | ||
| 73 | + name: quiver | ||
| 74 | + url: "https://pub.dartlang.org" | ||
| 75 | + source: hosted | ||
| 76 | + version: "2.0.3" | ||
| 77 | + sky_engine: | ||
| 78 | + dependency: transitive | ||
| 79 | + description: flutter | ||
| 80 | + source: sdk | ||
| 81 | + version: "0.0.99" | ||
| 82 | + source_span: | ||
| 83 | + dependency: transitive | ||
| 84 | + description: | ||
| 85 | + name: source_span | ||
| 86 | + url: "https://pub.dartlang.org" | ||
| 87 | + source: hosted | ||
| 88 | + version: "1.5.5" | ||
| 89 | + stack_trace: | ||
| 90 | + dependency: transitive | ||
| 91 | + description: | ||
| 92 | + name: stack_trace | ||
| 93 | + url: "https://pub.dartlang.org" | ||
| 94 | + source: hosted | ||
| 95 | + version: "1.9.3" | ||
| 96 | + stream_channel: | ||
| 97 | + dependency: transitive | ||
| 98 | + description: | ||
| 99 | + name: stream_channel | ||
| 100 | + url: "https://pub.dartlang.org" | ||
| 101 | + source: hosted | ||
| 102 | + version: "2.0.0" | ||
| 103 | + string_scanner: | ||
| 104 | + dependency: transitive | ||
| 105 | + description: | ||
| 106 | + name: string_scanner | ||
| 107 | + url: "https://pub.dartlang.org" | ||
| 108 | + source: hosted | ||
| 109 | + version: "1.0.4" | ||
| 110 | + term_glyph: | ||
| 111 | + dependency: transitive | ||
| 112 | + description: | ||
| 113 | + name: term_glyph | ||
| 114 | + url: "https://pub.dartlang.org" | ||
| 115 | + source: hosted | ||
| 116 | + version: "1.1.0" | ||
| 117 | + test_api: | ||
| 118 | + dependency: transitive | ||
| 119 | + description: | ||
| 120 | + name: test_api | ||
| 121 | + url: "https://pub.dartlang.org" | ||
| 122 | + source: hosted | ||
| 123 | + version: "0.2.5" | ||
| 124 | + typed_data: | ||
| 125 | + dependency: transitive | ||
| 126 | + description: | ||
| 127 | + name: typed_data | ||
| 128 | + url: "https://pub.dartlang.org" | ||
| 129 | + source: hosted | ||
| 130 | + version: "1.1.6" | ||
| 131 | + vector_math: | ||
| 132 | + dependency: transitive | ||
| 133 | + description: | ||
| 134 | + name: vector_math | ||
| 135 | + url: "https://pub.dartlang.org" | ||
| 136 | + source: hosted | ||
| 137 | + version: "2.0.8" | ||
| 138 | +sdks: | ||
| 139 | + dart: ">=2.2.2 <3.0.0" |
pubspec.yaml
0 → 100644
| 1 | +name: wakelock | ||
| 2 | +description: Wakelock is a Flutter plugin that allows you to easily toggle the Android and iOS screen wakelock on or off in order to prevent the screen from automatically turning off. | ||
| 3 | +version: 0.0.1 | ||
| 4 | +author: creativecreatorormaybenot | ||
| 5 | +homepage: https://github.com/creativecreatorormaybenot/wakelock | ||
| 6 | + | ||
| 7 | +environment: | ||
| 8 | + sdk: ">=2.1.0 <3.0.0" | ||
| 9 | + | ||
| 10 | +dependencies: | ||
| 11 | + flutter: | ||
| 12 | + sdk: flutter | ||
| 13 | + | ||
| 14 | +dev_dependencies: | ||
| 15 | + flutter_test: | ||
| 16 | + sdk: flutter | ||
| 17 | + | ||
| 18 | +flutter: | ||
| 19 | + plugin: | ||
| 20 | + androidPackage: wakelock.wakelock | ||
| 21 | + pluginClass: WakelockPlugin |
wakelock.iml
0 → 100644
| 1 | +<?xml version="1.0" encoding="UTF-8"?> | ||
| 2 | +<module type="JAVA_MODULE" version="4"> | ||
| 3 | + <component name="NewModuleRootManager" inherit-compiler-output="true"> | ||
| 4 | + <exclude-output /> | ||
| 5 | + <content url="file://$MODULE_DIR$"> | ||
| 6 | + <sourceFolder url="file://$MODULE_DIR$/lib" isTestSource="false" /> | ||
| 7 | + <excludeFolder url="file://$MODULE_DIR$/.dart_tool" /> | ||
| 8 | + <excludeFolder url="file://$MODULE_DIR$/.idea" /> | ||
| 9 | + <excludeFolder url="file://$MODULE_DIR$/.pub" /> | ||
| 10 | + <excludeFolder url="file://$MODULE_DIR$/build" /> | ||
| 11 | + <excludeFolder url="file://$MODULE_DIR$/example/.dart_tool" /> | ||
| 12 | + <excludeFolder url="file://$MODULE_DIR$/example/.pub" /> | ||
| 13 | + <excludeFolder url="file://$MODULE_DIR$/example/build" /> | ||
| 14 | + </content> | ||
| 15 | + <orderEntry type="sourceFolder" forTests="false" /> | ||
| 16 | + <orderEntry type="library" name="Dart SDK" level="project" /> | ||
| 17 | + <orderEntry type="library" name="Flutter Plugins" level="project" /> | ||
| 18 | + </component> | ||
| 19 | +</module> |
-
Please register or login to post a comment