Skip to content

Instantly share code, notes, and snippets.

@nathansamson
Last active July 21, 2018 21:49
Show Gist options
  • Save nathansamson/ac5a11e8a4d8e6d4d8b19610a267c931 to your computer and use it in GitHub Desktop.
Save nathansamson/ac5a11e8a4d8e6d4d8b19610a267c931 to your computer and use it in GitHub Desktop.
BottomNavigationBar issue
import 'dart:async';
import 'package:flutter/material.dart';
void main() => runApp(new MyApp());
typedef void ThemeChangeCallback(ThemeData theme);
class MyApp extends StatefulWidget {
@override
_MyAppState createState() => new _MyAppState();
static ThemeChangeCallback themeChangeCallback;
static setThemeCallback(ThemeChangeCallback newThemeChangeCallback) {
themeChangeCallback = newThemeChangeCallback;
}
static void themeChanged(ThemeData newTheme) {
themeChangeCallback(newTheme);
}
}
class _MyAppState extends State<MyApp> {
ThemeData currentTheme;
@override
void initState() {
super.initState();
MyApp.setThemeCallback((ThemeData newTheme) {
setState(() {
print('CHANGED THEME');
currentTheme = newTheme;
});
});
currentTheme = new ThemeData(
primarySwatch: Colors.blue,
);
}
@override
Widget build(BuildContext context) {
print('NEW APP');
return new MaterialApp(
title: 'Flutter Demo',
theme: currentTheme,
home: new MyHomePage(title: 'Flutter Demo Home Page'),
);
}
}
class MyHomePage extends StatefulWidget {
MyHomePage({Key key, this.title}) : super(key: key);
// This widget is the home page of your application. It is stateful, meaning
// that it has a State object (defined below) that contains fields that affect
// how it looks.
// This class is the configuration for the state. It holds the values (in this
// case the title) provided by the parent (in this case the App widget) and
// used by the build method of the State. Fields in a Widget subclass are
// always marked "final".
final String title;
@override
_MyHomePageState createState() => new _MyHomePageState();
}
class _MyHomePageState extends State<MyHomePage> {
Future<void> login() async {
print('THEME CHANGE');
MyApp.themeChanged(new ThemeData(
// This is the theme of your application.
//
// Try running your application with "flutter run". You'll see the
// application has a blue toolbar. Then, without quitting the app, try
// changing the primarySwatch below to Colors.green and then invoke
// "hot reload" (press "r" in the console where you ran "flutter run",
// or press Run > Flutter Hot Reload in IntelliJ). Notice that the
// counter didn't reset back to zero; the application is not restarted.
primarySwatch: Colors.yellow,
));
Navigator.of(context).pushReplacement(
MaterialPageRoute(
builder: (context) =>
DashboardPage(),
));
}
@override
Widget build(BuildContext context) {
// This method is rerun every time setState is called, for instance as done
// by the _incrementCounter method above.
//
// The Flutter framework has been optimized to make rerunning build methods
// fast, so that you can just rebuild anything that needs updating rather
// than having to individually change instances of widgets.
return new Scaffold(
appBar: new AppBar(
// Here we take the value from the MyHomePage object that was created by
// the App.build method, and use it to set our appbar title.
title: new Text(widget.title),
),
body: new Center(
child: new RaisedButton(onPressed: login)
),
);
}
}
class DashboardPage extends StatefulWidget {
DashboardPage({Key key}) : super(key: key);
@override
_MyDashboardPageState createState() => new _MyDashboardPageState();
}
class _MyDashboardPageState extends State<DashboardPage> {
int currentIndex;
@override
initState() {
super.initState();
currentIndex = 0;
}
Widget build(BuildContext context) {
print(Theme.of(context).primaryColor);
return new Scaffold(
bottomNavigationBar: new BottomNavigationBar(
items: [
new BottomNavigationBarItem(
title: new Text("Page 1"),
backgroundColor: Theme.of(context).primaryColor,
icon: new Icon(Icons.dashboard),
),
new BottomNavigationBarItem(
title: new Text("Page 2"),
backgroundColor: Theme.of(context).primaryColor,
icon: new Icon(Icons.menu),
),
],
currentIndex: currentIndex,
onTap: (index) {
setState(() {
currentIndex = index;
});
},
type: BottomNavigationBarType.shifting,
),
body: new Center(
child: new Text("Content $currentIndex")
)
);
}
}
nathan@linux bottom_navigation_bar_theme]$ flutter run -v
[ +21 ms] [/home/nathan/flutter/] git rev-parse --abbrev-ref --symbolic @{u}
[ +20 ms] Exit code 0 from: git rev-parse --abbrev-ref --symbolic @{u}
[ ] origin/beta
[ ] [/home/nathan/flutter/] git rev-parse --abbrev-ref HEAD
[ +5 ms] Exit code 0 from: git rev-parse --abbrev-ref HEAD
[ ] beta
[ ] [/home/nathan/flutter/] git ls-remote --get-url origin
[ +4 ms] Exit code 0 from: git ls-remote --get-url origin
[ ] https://github.com/flutter/flutter.git
[ ] [/home/nathan/flutter/] git log -n 1 --pretty=format:%H
[ +5 ms] Exit code 0 from: git log -n 1 --pretty=format:%H
[ ] c7ea3ca377e909469c68f2ab878a5bc53d3cf66b
[ ] [/home/nathan/flutter/] git log -n 1 --pretty=format:%ar
[ +5 ms] Exit code 0 from: git log -n 1 --pretty=format:%ar
[ ] 8 weeks ago
[ ] [/home/nathan/flutter/] git describe --match v*.*.* --first-parent --long --tags
[ +5 ms] Exit code 0 from: git describe --match v*.*.* --first-parent --long --tags
[ ] v0.5.1-0-gc7ea3ca37
[ +99 ms] /home/nathan/Android/Sdk/platform-tools/adb devices -l
[ +3 ms] Exit code 0 from: /home/nathan/Android/Sdk/platform-tools/adb devices -l
[ ] List of devices attached
192.168.56.101:5555 device product:vbox86p model:Google device:vbox86p
[ +117 ms] /home/nathan/Android/Sdk/platform-tools/adb -s 192.168.56.101:5555 shell getprop
[ +25 ms] ro.hardware = vbox86
[ ] ro.build.characteristics = nosdcard
[ +439 ms] Launching lib/main.dart on Google in debug mode...
[ +3 ms] Initializing gradle...
[ +5 ms] Using gradle from /home/nathan/AndroidStudioProjects/bottom_navigation_bar_theme/android/gradlew.
[ +45 ms] /home/nathan/AndroidStudioProjects/bottom_navigation_bar_theme/android/gradlew -v
[ +464 ms]
------------------------------------------------------------
Gradle 4.1
------------------------------------------------------------
Build time: 2017-08-07 14:38:48 UTC
Revision: 941559e020f6c357ebb08d5c67acdb858a3defc2
Groovy: 2.4.11
Ant: Apache Ant(TM) version 1.9.6 compiled on June 29 2015
JVM: 1.8.0_152-release (JetBrains s.r.o 25.152-b01)
OS: Linux 4.17.3-200.fc28.x86_64 amd64
[ +1 ms] Resolving dependencies...
[ ] [android/] /home/nathan/AndroidStudioProjects/bottom_navigation_bar_theme/android/gradlew app:properties
[ +529 ms] :app:properties
------------------------------------------------------------
Project :app
------------------------------------------------------------
allprojects: [project ':app']
android: com.android.build.gradle.AppExtension_Decorated@6741ef9a
androidDependencies: task ':app:androidDependencies'
ant: org.gradle.api.internal.project.DefaultAntBuilder@1ade0de0
antBuilderFactory: org.gradle.api.internal.project.DefaultAntBuilderFactory@1f4a5ae8
archivesBaseName: app
artifacts: org.gradle.api.internal.artifacts.dsl.DefaultArtifactHandler_Decorated@4b10197a
asDynamicObject: DynamicObject for project ':app'
assemble: task ':app:assemble'
assembleAndroidTest: task ':app:assembleAndroidTest'
assembleDebug: task ':app:assembleDebug'
assembleDebugAndroidTest: task ':app:assembleDebugAndroidTest'
assembleDebugUnitTest: task ':app:assembleDebugUnitTest'
assembleProfile: task ':app:assembleProfile'
assembleProfileUnitTest: task ':app:assembleProfileUnitTest'
assembleRelease: task ':app:assembleRelease'
assembleReleaseUnitTest: task ':app:assembleReleaseUnitTest'
baseClassLoaderScope: org.gradle.api.internal.initialization.DefaultClassLoaderScope@23c512bd
buildDependents: task ':app:buildDependents'
buildDir: /home/nathan/AndroidStudioProjects/bottom_navigation_bar_theme/build/app
buildFile: /home/nathan/AndroidStudioProjects/bottom_navigation_bar_theme/android/app/build.gradle
buildNeeded: task ':app:buildNeeded'
buildOutputs: BaseVariantOutput container
buildScriptSource: org.gradle.groovy.scripts.UriScriptSource@499eba28
buildscript: org.gradle.api.internal.initialization.DefaultScriptHandler@44e34e9
bundleAppClassesDebug: task ':app:bundleAppClassesDebug'
bundleAppClassesDebugAndroidTest: task ':app:bundleAppClassesDebugAndroidTest'
bundleAppClassesDebugUnitTest: task ':app:bundleAppClassesDebugUnitTest'
bundleAppClassesProfile: task ':app:bundleAppClassesProfile'
bundleAppClassesProfileUnitTest: task ':app:bundleAppClassesProfileUnitTest'
bundleAppClassesRelease: task ':app:bundleAppClassesRelease'
bundleAppClassesReleaseUnitTest: task ':app:bundleAppClassesReleaseUnitTest'
check: task ':app:check'
checkDebugManifest: task ':app:checkDebugManifest'
checkProfileManifest: task ':app:checkProfileManifest'
checkReleaseManifest: task ':app:checkReleaseManifest'
childProjects: {}
class: class org.gradle.api.internal.project.DefaultProject_Decorated
classLoaderScope: org.gradle.api.internal.initialization.DefaultClassLoaderScope@4f5e26d3
cleanBuildCache: task ':app:cleanBuildCache'
compileDebugAidl: task ':app:compileDebugAidl'
compileDebugAndroidTestAidl: task ':app:compileDebugAndroidTestAidl'
compileDebugAndroidTestJavaWithJavac: task ':app:compileDebugAndroidTestJavaWithJavac'
compileDebugAndroidTestNdk: task ':app:compileDebugAndroidTestNdk'
compileDebugAndroidTestRenderscript: task ':app:compileDebugAndroidTestRenderscript'
compileDebugAndroidTestShaders: task ':app:compileDebugAndroidTestShaders'
compileDebugAndroidTestSources: task ':app:compileDebugAndroidTestSources'
compileDebugJavaWithJavac: task ':app:compileDebugJavaWithJavac'
compileDebugNdk: task ':app:compileDebugNdk'
compileDebugRenderscript: task ':app:compileDebugRenderscript'
compileDebugShaders: task ':app:compileDebugShaders'
compileDebugSources: task ':app:compileDebugSources'
compileDebugUnitTestJavaWithJavac: task ':app:compileDebugUnitTestJavaWithJavac'
compileDebugUnitTestSources: task ':app:compileDebugUnitTestSources'
compileLint: task ':app:compileLint'
compileProfileAidl: task ':app:compileProfileAidl'
compileProfileJavaWithJavac: task ':app:compileProfileJavaWithJavac'
compileProfileNdk: task ':app:compileProfileNdk'
compileProfileRenderscript: task ':app:compileProfileRenderscript'
compileProfileShaders: task ':app:compileProfileShaders'
compileProfileSources: task ':app:compileProfileSources'
compileProfileUnitTestJavaWithJavac: task ':app:compileProfileUnitTestJavaWithJavac'
compileProfileUnitTestSources: task ':app:compileProfileUnitTestSources'
compileReleaseAidl: task ':app:compileReleaseAidl'
compileReleaseJavaWithJavac: task ':app:compileReleaseJavaWithJavac'
compileReleaseNdk: task ':app:compileReleaseNdk'
compileReleaseRenderscript: task ':app:compileReleaseRenderscript'
compileReleaseShaders: task ':app:compileReleaseShaders'
compileReleaseSources: task ':app:compileReleaseSources'
compileReleaseUnitTestJavaWithJavac: task ':app:compileReleaseUnitTestJavaWithJavac'
compileReleaseUnitTestSources: task ':app:compileReleaseUnitTestSources'
components: SoftwareComponentInternal set
configurationActions: org.gradle.configuration.project.DefaultProjectConfigurationActionContainer@4485957f
configurationTargetIdentifier: org.gradle.configuration.ConfigurationTargetIdentifier$1@7876283d
configurations: configuration container
connectedAndroidTest: task ':app:connectedAndroidTest'
connectedCheck: task ':app:connectedCheck'
connectedDebugAndroidTest: task ':app:connectedDebugAndroidTest'
consumeConfigAttr: task ':app:consumeConfigAttr'
convention: org.gradle.api.internal.plugins.DefaultConvention@deaa2a6
copyFlutterAssetsDebug: task ':app:copyFlutterAssetsDebug'
copyFlutterAssetsProfile: task ':app:copyFlutterAssetsProfile'
copyFlutterAssetsRelease: task ':app:copyFlutterAssetsRelease'
createDebugCompatibleScreenManifests: task ':app:createDebugCompatibleScreenManifests'
createProfileCompatibleScreenManifests: task ':app:createProfileCompatibleScreenManifests'
createReleaseCompatibleScreenManifests: task ':app:createReleaseCompatibleScreenManifests'
defaultArtifacts: org.gradle.api.internal.plugins.DefaultArtifactPublicationSet_Decorated@33bc6576
defaultTasks: []
deferredProjectConfiguration: org.gradle.api.internal.project.DeferredProjectConfiguration@5bfa3013
dependencies: org.gradle.api.internal.artifacts.dsl.dependencies.DefaultDependencyHandler_Decorated@1284dc91
depth: 1
description: null
deviceAndroidTest: task ':app:deviceAndroidTest'
deviceCheck: task ':app:deviceCheck'
displayName: project ':app'
distsDir: /home/nathan/AndroidStudioProjects/bottom_navigation_bar_theme/build/app/distributions
distsDirName: distributions
docsDir: /home/nathan/AndroidStudioProjects/bottom_navigation_bar_theme/build/app/docs
docsDirName: docs
ext: org.gradle.api.internal.plugins.DefaultExtraPropertiesExtension@4aa3a3f5
extensions: org.gradle.api.internal.plugins.DefaultConvention@deaa2a6
extractProguardFiles: task ':app:extractProguardFiles'
fileOperations: org.gradle.api.internal.file.DefaultFileOperations@1a64e802
fileResolver: org.gradle.api.internal.file.BaseDirFileResolver@101439f5
flutter: FlutterExtension_Decorated@24c00f32
flutterBuildDebug: task ':app:flutterBuildDebug'
flutterBuildProfile: task ':app:flutterBuildProfile'
flutterBuildRelease: task ':app:flutterBuildRelease'
flutterBuildX86Jar: task ':app:flutterBuildX86Jar'
generateDebugAndroidTestAssets: task ':app:generateDebugAndroidTestAssets'
generateDebugAndroidTestBuildConfig: task ':app:generateDebugAndroidTestBuildConfig'
generateDebugAndroidTestResValues: task ':app:generateDebugAndroidTestResValues'
generateDebugAndroidTestResources: task ':app:generateDebugAndroidTestResources'
generateDebugAndroidTestSources: task ':app:generateDebugAndroidTestSources'
generateDebugAssets: task ':app:generateDebugAssets'
generateDebugBuildConfig: task ':app:generateDebugBuildConfig'
generateDebugResValues: task ':app:generateDebugResValues'
generateDebugResources: task ':app:generateDebugResources'
generateDebugSources: task ':app:generateDebugSources'
generateProfileAssets: task ':app:generateProfileAssets'
generateProfileBuildConfig: task ':app:generateProfileBuildConfig'
generateProfileResValues: task ':app:generateProfileResValues'
generateProfileResources: task ':app:generateProfileResources'
generateProfileSources: task ':app:generateProfileSources'
generateReleaseAssets: task ':app:generateReleaseAssets'
generateReleaseBuildConfig: task ':app:generateReleaseBuildConfig'
generateReleaseResValues: task ':app:generateReleaseResValues'
generateReleaseResources: task ':app:generateReleaseResources'
generateReleaseSources: task ':app:generateReleaseSources'
gradle: build 'android'
group: android
identityPath: :app
inheritedScope: org.gradle.api.internal.ExtensibleDynamicObject$InheritedDynamicObject@732bac54
installDebug: task ':app:installDebug'
installDebugAndroidTest: task ':app:installDebugAndroidTest'
installProfile: task ':app:installProfile'
installRelease: task ':app:installRelease'
javaPreCompileDebug: task ':app:javaPreCompileDebug'
javaPreCompileDebugAndroidTest: task ':app:javaPreCompileDebugAndroidTest'
javaPreCompileDebugUnitTest: task ':app:javaPreCompileDebugUnitTest'
javaPreCompileProfile: task ':app:javaPreCompileProfile'
javaPreCompileProfileUnitTest: task ':app:javaPreCompileProfileUnitTest'
javaPreCompileRelease: task ':app:javaPreCompileRelease'
javaPreCompileReleaseUnitTest: task ':app:javaPreCompileReleaseUnitTest'
layout: org.gradle.api.internal.file.DefaultProjectLayout@4e326ecb
libsDir: /home/nathan/AndroidStudioProjects/bottom_navigation_bar_theme/build/app/libs
libsDirName: libs
lint: task ':app:lint'
lintDebug: task ':app:lintDebug'
lintProfile: task ':app:lintProfile'
lintRelease: task ':app:lintRelease'
lintVitalRelease: task ':app:lintVitalRelease'
logger: org.gradle.internal.logging.slf4j.OutputEventListenerBackedLogger@7506e973
logging: org.gradle.internal.logging.services.DefaultLoggingManager@7f583d69
mergeDebugAndroidTestAssets: task ':app:mergeDebugAndroidTestAssets'
mergeDebugAndroidTestJniLibFolders: task ':app:mergeDebugAndroidTestJniLibFolders'
mergeDebugAndroidTestResources: task ':app:mergeDebugAndroidTestResources'
mergeDebugAndroidTestShaders: task ':app:mergeDebugAndroidTestShaders'
mergeDebugAssets: task ':app:mergeDebugAssets'
mergeDebugJniLibFolders: task ':app:mergeDebugJniLibFolders'
mergeDebugResources: task ':app:mergeDebugResources'
mergeDebugShaders: task ':app:mergeDebugShaders'
mergeProfileAssets: task ':app:mergeProfileAssets'
mergeProfileJniLibFolders: task ':app:mergeProfileJniLibFolders'
mergeProfileResources: task ':app:mergeProfileResources'
mergeProfileShaders: task ':app:mergeProfileShaders'
mergeReleaseAssets: task ':app:mergeReleaseAssets'
mergeReleaseJniLibFolders: task ':app:mergeReleaseJniLibFolders'
mergeReleaseResources: task ':app:mergeReleaseResources'
mergeReleaseShaders: task ':app:mergeReleaseShaders'
mockableAndroidJar: task ':app:mockableAndroidJar'
modelRegistry: org.gradle.model.internal.registry.DefaultModelRegistry@5b45142f
modelSchemaStore: org.gradle.model.internal.manage.schema.extract.DefaultModelSchemaStore@76417ddc
module: org.gradle.api.internal.artifacts.ProjectBackedModule@2e6cea90
name: app
normalization: org.gradle.normalization.internal.DefaultInputNormalizationHandler_Decorated@75a24a1f
objects: org.gradle.api.internal.model.DefaultObjectFactory@2056a32b
org.gradle.jvmargs: -Xmx1536M
packageDebug: task ':app:packageDebug'
packageDebugAndroidTest: task ':app:packageDebugAndroidTest'
packageProfile: task ':app:packageProfile'
packageRelease: task ':app:packageRelease'
parent: root project 'android'
parentIdentifier: root project 'android'
path: :app
platformAttrExtractor: task ':app:platformAttrExtractor'
pluginManager: org.gradle.api.internal.plugins.DefaultPluginManager_Decorated@28bb3656
plugins: [org.gradle.api.plugins.HelpTasksPlugin@6f0bf050, com.android.build.gradle.api.AndroidBasePlugin@278d466e, org.gradle.language.base.plugins.LifecycleBasePlugin@232ddd42, org.gradle.api.plugins.BasePlugin@7a4a0595, org.gradle.api.plugins.ReportingBasePlugin@7cb12da2, org.gradle.platform.base.plugins.ComponentBasePlugin@6a6c9fdb, org.gradle.language.base.plugins.LanguageBasePlugin@1fc56309, org.gradle.platform.base.plugins.BinaryBasePlugin@25e95b28, org.gradle.api.plugins.JavaBasePlugin@21a0a7e, com.android.build.gradle.internal.coverage.JacocoPlugin@2eec1375, com.android.build.gradle.AppPlugin@f5c427, FlutterPlugin@527b8fa2]
preBuild: task ':app:preBuild'
preDebugAndroidTestBuild: task ':app:preDebugAndroidTestBuild'
preDebugBuild: task ':app:preDebugBuild'
preDebugUnitTestBuild: task ':app:preDebugUnitTestBuild'
preProfileBuild: task ':app:preProfileBuild'
preProfileUnitTestBuild: task ':app:preProfileUnitTestBuild'
preReleaseBuild: task ':app:preReleaseBuild'
preReleaseUnitTestBuild: task ':app:preReleaseUnitTestBuild'
prepareLintJar: task ':app:prepareLintJar'
processDebugAndroidTestJavaRes: task ':app:processDebugAndroidTestJavaRes'
processDebugAndroidTestManifest: task ':app:processDebugAndroidTestManifest'
processDebugAndroidTestResources: task ':app:processDebugAndroidTestResources'
processDebugJavaRes: task ':app:processDebugJavaRes'
processDebugManifest: task ':app:processDebugManifest'
processDebugResources: task ':app:processDebugResources'
processDebugUnitTestJavaRes: task ':app:processDebugUnitTestJavaRes'
processOperations: org.gradle.api.internal.file.DefaultFileOperations@1a64e802
processProfileJavaRes: task ':app:processProfileJavaRes'
processProfileManifest: task ':app:processProfileManifest'
processProfileResources: task ':app:processProfileResources'
processProfileUnitTestJavaRes: task ':app:processProfileUnitTestJavaRes'
processReleaseJavaRes: task ':app:processReleaseJavaRes'
processReleaseManifest: task ':app:processReleaseManifest'
processReleaseResources: task ':app:processReleaseResources'
processReleaseUnitTestJavaRes: task ':app:processReleaseUnitTestJavaRes'
project: project ':app'
projectConfigurator: org.gradle.api.internal.project.BuildOperationCrossProjectConfigurator@16b6f55d
projectDir: /home/nathan/AndroidStudioProjects/bottom_navigation_bar_theme/android/app
projectEvaluationBroadcaster: ProjectEvaluationListener broadcast
projectEvaluator: org.gradle.configuration.project.LifecycleProjectEvaluator@65a16fc8
projectPath: :app
projectRegistry: org.gradle.api.internal.project.DefaultProjectRegistry@23423d1
properties: {...}
providers: org.gradle.api.internal.provider.DefaultProviderFactory@5c42dc36
reporting: org.gradle.api.reporting.ReportingExtension_Decorated@73ccac47
reportsDir: /home/nathan/AndroidStudioProjects/bottom_navigation_bar_theme/build/app/reports
repositories: repository container
resolveConfigAttr: task ':app:resolveConfigAttr'
resources: org.gradle.api.internal.resources.DefaultResourceHandler@52f1b37e
rootDir: /home/nathan/AndroidStudioProjects/bottom_navigation_bar_theme/android
rootProject: root project 'android'
scriptHandlerFactory: org.gradle.api.internal.initialization.DefaultScriptHandlerFactory@3c4059c7
scriptPluginFactory: org.gradle.configuration.ScriptPluginFactorySelector@1fc9cf35
serviceRegistryFactory: org.gradle.internal.service.scopes.ProjectScopeServices$4@9f1f61f
services: ProjectScopeServices
signingReport: task ':app:signingReport'
sourceCompatibility: 1.8
sourceSets: SourceSet container
splitsDiscoveryTaskDebug: task ':app:splitsDiscoveryTaskDebug'
splitsDiscoveryTaskDebugAndroidTest: task ':app:splitsDiscoveryTaskDebugAndroidTest'
splitsDiscoveryTaskProfile: task ':app:splitsDiscoveryTaskProfile'
splitsDiscoveryTaskRelease: task ':app:splitsDiscoveryTaskRelease'
standardOutputCapture: org.gradle.internal.logging.services.DefaultLoggingManager@7f583d69
state: project state 'EXECUTED'
status: integration
subprojects: []
targetCompatibility: 1.8
tasks: task set
test: task ':app:test'
testDebugUnitTest: task ':app:testDebugUnitTest'
testProfileUnitTest: task ':app:testProfileUnitTest'
testReleaseUnitTest: task ':app:testReleaseUnitTest'
testReportDir: /home/nathan/AndroidStudioProjects/bottom_navigation_bar_theme/build/app/reports/tests
testReportDirName: tests
testResultsDir: /home/nathan/AndroidStudioProjects/bottom_navigation_bar_theme/build/app/test-results
testResultsDirName: test-results
transformClassesWithDexBuilderForDebug: task ':app:transformClassesWithDexBuilderForDebug'
transformClassesWithDexBuilderForDebugAndroidTest: task ':app:transformClassesWithDexBuilderForDebugAndroidTest'
transformClassesWithDexBuilderForProfile: task ':app:transformClassesWithDexBuilderForProfile'
transformClassesWithPreDexForRelease: task ':app:transformClassesWithPreDexForRelease'
transformDexArchiveWithDexMergerForDebug: task ':app:transformDexArchiveWithDexMergerForDebug'
transformDexArchiveWithDexMergerForDebugAndroidTest: task ':app:transformDexArchiveWithDexMergerForDebugAndroidTest'
transformDexArchiveWithDexMergerForProfile: task ':app:transformDexArchiveWithDexMergerForProfile'
transformDexArchiveWithExternalLibsDexMergerForDebug: task ':app:transformDexArchiveWithExternalLibsDexMergerForDebug'
transformDexArchiveWithExternalLibsDexMergerForDebugAndroidTest: task ':app:transformDexArchiveWithExternalLibsDexMergerForDebugAndroidTest'
transformDexArchiveWithExternalLibsDexMergerForProfile: task ':app:transformDexArchiveWithExternalLibsDexMergerForProfile'
transformDexWithDexForRelease: task ':app:transformDexWithDexForRelease'
transformNativeLibsWithMergeJniLibsForDebug: task ':app:transformNativeLibsWithMergeJniLibsForDebug'
transformNativeLibsWithMergeJniLibsForDebugAndroidTest: task ':app:transformNativeLibsWithMergeJniLibsForDebugAndroidTest'
transformNativeLibsWithMergeJniLibsForProfile: task ':app:transformNativeLibsWithMergeJniLibsForProfile'
transformNativeLibsWithMergeJniLibsForRelease: task ':app:transformNativeLibsWithMergeJniLibsForRelease'
transformResourcesWithMergeJavaResForDebug: task ':app:transformResourcesWithMergeJavaResForDebug'
transformResourcesWithMergeJavaResForDebugAndroidTest: task ':app:transformResourcesWithMergeJavaResForDebugAndroidTest'
transformResourcesWithMergeJavaResForDebugUnitTest: task ':app:transformResourcesWithMergeJavaResForDebugUnitTest'
transformResourcesWithMergeJavaResForProfile: task ':app:transformResourcesWithMergeJavaResForProfile'
transformResourcesWithMergeJavaResForProfileUnitTest: task ':app:transformResourcesWithMergeJavaResForProfileUnitTest'
transformResourcesWithMergeJavaResForRelease: task ':app:transformResourcesWithMergeJavaResForRelease'
transformResourcesWithMergeJavaResForReleaseUnitTest: task ':app:transformResourcesWithMergeJavaResForReleaseUnitTest'
uninstallAll: task ':app:uninstallAll'
uninstallDebug: task ':app:uninstallDebug'
uninstallDebugAndroidTest: task ':app:uninstallDebugAndroidTest'
uninstallProfile: task ':app:uninstallProfile'
uninstallRelease: task ':app:uninstallRelease'
validateSigningDebug: task ':app:validateSigningDebug'
validateSigningDebugAndroidTest: task ':app:validateSigningDebugAndroidTest'
validateSigningProfile: task ':app:validateSigningProfile'
validateSigningRelease: task ':app:validateSigningRelease'
version: unspecified
writeDebugApplicationId: task ':app:writeDebugApplicationId'
writeProfileApplicationId: task ':app:writeProfileApplicationId'
writeReleaseApplicationId: task ':app:writeReleaseApplicationId'
BUILD SUCCESSFUL in 0s
1 actionable task: 1 executed
[ +4 ms] /home/nathan/Android/Sdk/build-tools/27.0.3/aapt dump badging build/app/outputs/apk/app.apk
[ +6 ms] Exit code 0 from: /home/nathan/Android/Sdk/build-tools/27.0.3/aapt dump badging build/app/outputs/apk/app.apk
[ ] package: name='be.nathansamson.bottomnavigationbartheme' versionCode='1' versionName='1.0' platformBuildVersionName=''
sdkVersion:'16'
targetSdkVersion:'27'
uses-permission: name='android.permission.INTERNET'
application-label:'bottom_navigation_bar_theme'
application-icon-160:'res/mipmap-mdpi-v4/ic_launcher.png'
application-icon-240:'res/mipmap-hdpi-v4/ic_launcher.png'
application-icon-320:'res/mipmap-xhdpi-v4/ic_launcher.png'
application-icon-480:'res/mipmap-xxhdpi-v4/ic_launcher.png'
application-icon-640:'res/mipmap-xxxhdpi-v4/ic_launcher.png'
application: label='bottom_navigation_bar_theme' icon='res/mipmap-mdpi-v4/ic_launcher.png'
application-debuggable
launchable-activity: name='be.nathansamson.bottomnavigationbartheme.MainActivity' label='' icon=''
feature-group: label=''
uses-feature: name='android.hardware.faketouch'
uses-implied-feature: name='android.hardware.faketouch' reason='default feature for all apps'
main
supports-screens: 'small' 'normal' 'large' 'xlarge'
supports-any-density: 'true'
locales: '--_--'
densities: '160' '240' '320' '480' '640'
native-code: 'armeabi-v7a' 'x86' 'x86_64'
[ +4 ms] /home/nathan/Android/Sdk/platform-tools/adb -s 192.168.56.101:5555 logcat -v time -t 1
[ +14 ms] Exit code 0 from: /home/nathan/Android/Sdk/platform-tools/adb -s 192.168.56.101:5555 logcat -v time -t 1
[ ] --------- beginning of main
07-21 21:42:44.523 I/logcat ( 2760): type=1400 audit(0.0:1303): avc: denied { read write } for path="socket:[10473]" dev="sockfs" ino=10473 scontext=u:r:logpersist:s0 tcontext=u:r:init:s0 tclass=unix_stream_socket permissive=1
[ +2 ms] /home/nathan/Android/Sdk/platform-tools/adb -s 192.168.56.101:5555 logcat -v time
[ +241 ms] DependencyChecker: /home/nathan/AndroidStudioProjects/bottom_navigation_bar_theme/lib/main.dart is newer than 2018-07-21 23:28:19.937
[ +2 ms] /home/nathan/Android/Sdk/platform-tools/adb version
[ +13 ms] Android Debug Bridge version 1.0.39
Version 0.0.1-4500957
Installed as /home/nathan/Android/Sdk/platform-tools/adb
[ +2 ms] /home/nathan/Android/Sdk/platform-tools/adb start-server
[ +61 ms] Building APK
[ +3 ms] Running 'gradlew assembleDebug'...
[ +1 ms] [android/] /home/nathan/AndroidStudioProjects/bottom_navigation_bar_theme/android/gradlew -Ptarget=/home/nathan/AndroidStudioProjects/bottom_navigation_bar_theme/lib/main.dart -Ppreview-dart-2=true -Pfilesystem-scheme=org-dartlang-root assembleDebug
[ +473 ms] :app:preBuild UP-TO-DATE
[ +8 ms] :app:preDebugBuild UP-TO-DATE
[ ] :app:compileDebugAidl UP-TO-DATE
[ ] :app:compileDebugRenderscript UP-TO-DATE
[ +39 ms] :app:flutterBuildX86Jar UP-TO-DATE
[ ] :app:checkDebugManifest UP-TO-DATE
[ ] :app:generateDebugBuildConfig UP-TO-DATE
[ ] :app:prepareLintJar UP-TO-DATE
[ ] :app:cleanMergeDebugAssets
[+3680 ms] :app:flutterBuildDebug
[ ] :app:mergeDebugShaders UP-TO-DATE
[ ] :app:compileDebugShaders UP-TO-DATE
[ ] :app:generateDebugAssets UP-TO-DATE
[ ] :app:mergeDebugAssets
[ +90 ms] :app:copyFlutterAssetsDebug
[ ] :app:generateDebugResValues UP-TO-DATE
[ ] :app:generateDebugResources UP-TO-DATE
[ ] :app:mergeDebugResources UP-TO-DATE
[ ] :app:createDebugCompatibleScreenManifests UP-TO-DATE
[ +8 ms] :app:processDebugManifest UP-TO-DATE
[ ] :app:splitsDiscoveryTaskDebug UP-TO-DATE
[ ] :app:processDebugResources UP-TO-DATE
[ ] :app:generateDebugSources UP-TO-DATE
[ ] :app:javaPreCompileDebug UP-TO-DATE
[ ] :app:compileDebugJavaWithJavac UP-TO-DATE
[ ] :app:compileDebugNdk NO-SOURCE
[ ] :app:compileDebugSources UP-TO-DATE
[ +39 ms] :app:transformClassesWithDexBuilderForDebug UP-TO-DATE
[ ] :app:transformDexArchiveWithExternalLibsDexMergerForDebug UP-TO-DATE
[ ] :app:transformDexArchiveWithDexMergerForDebug UP-TO-DATE
[ ] :app:mergeDebugJniLibFolders UP-TO-DATE
[ ] :app:transformNativeLibsWithMergeJniLibsForDebug UP-TO-DATE
[ ] :app:processDebugJavaRes NO-SOURCE
[ ] :app:transformResourcesWithMergeJavaResForDebug UP-TO-DATE
[ ] :app:validateSigningDebug
[+1894 ms] :app:packageDebug
[ ] :app:assembleDebug
[ ] BUILD SUCCESSFUL in 6s
[ ] 29 actionable tasks: 6 executed, 23 up-to-date
[ +375 ms] calculateSha: /home/nathan/AndroidStudioProjects/bottom_navigation_bar_theme/build/app/outputs/apk/app.apk
[ +364 ms] Built build/app/outputs/apk/debug/app-debug.apk.
[ ] /home/nathan/Android/Sdk/build-tools/27.0.3/aapt dump badging build/app/outputs/apk/app.apk
[ +7 ms] Exit code 0 from: /home/nathan/Android/Sdk/build-tools/27.0.3/aapt dump badging build/app/outputs/apk/app.apk
[ ] package: name='be.nathansamson.bottomnavigationbartheme' versionCode='1' versionName='1.0' platformBuildVersionName=''
sdkVersion:'16'
targetSdkVersion:'27'
uses-permission: name='android.permission.INTERNET'
application-label:'bottom_navigation_bar_theme'
application-icon-160:'res/mipmap-mdpi-v4/ic_launcher.png'
application-icon-240:'res/mipmap-hdpi-v4/ic_launcher.png'
application-icon-320:'res/mipmap-xhdpi-v4/ic_launcher.png'
application-icon-480:'res/mipmap-xxhdpi-v4/ic_launcher.png'
application-icon-640:'res/mipmap-xxxhdpi-v4/ic_launcher.png'
application: label='bottom_navigation_bar_theme' icon='res/mipmap-mdpi-v4/ic_launcher.png'
application-debuggable
launchable-activity: name='be.nathansamson.bottomnavigationbartheme.MainActivity' label='' icon=''
feature-group: label=''
uses-feature: name='android.hardware.faketouch'
uses-implied-feature: name='android.hardware.faketouch' reason='default feature for all apps'
main
supports-screens: 'small' 'normal' 'large' 'xlarge'
supports-any-density: 'true'
locales: '--_--'
densities: '160' '240' '320' '480' '640'
native-code: 'armeabi-v7a' 'x86' 'x86_64'
[ ] Stopping app 'app.apk' on Google.
[ ] /home/nathan/Android/Sdk/platform-tools/adb -s 192.168.56.101:5555 shell am force-stop be.nathansamson.bottomnavigationbartheme
[ +52 ms] /home/nathan/Android/Sdk/platform-tools/adb -s 192.168.56.101:5555 shell pm list packages be.nathansamson.bottomnavigationbartheme
[ +287 ms] package:be.nathansamson.bottomnavigationbartheme
[ +2 ms] /home/nathan/Android/Sdk/platform-tools/adb -s 192.168.56.101:5555 shell cat /data/local/tmp/sky.be.nathansamson.bottomnavigationbartheme.sha1
[ +20 ms] e3cb2019526f805919a63279f470970606cc60e8
[ +1 ms] Installing APK.
[ +1 ms] /home/nathan/Android/Sdk/platform-tools/adb version
[ +12 ms] Android Debug Bridge version 1.0.39
Version 0.0.1-4500957
Installed as /home/nathan/Android/Sdk/platform-tools/adb
[ ] /home/nathan/Android/Sdk/platform-tools/adb start-server
[ +11 ms] Installing build/app/outputs/apk/app.apk...
[ ] /home/nathan/Android/Sdk/platform-tools/adb -s 192.168.56.101:5555 install -r build/app/outputs/apk/app.apk
[+1744 ms] Success
[ +1 ms] /home/nathan/Android/Sdk/platform-tools/adb -s 192.168.56.101:5555 shell echo -n 4db504e6bd08c7ec2373ffbbef6fa8e434b78dff > /data/local/tmp/sky.be.nathansamson.bottomnavigationbartheme.sha1
[ +21 ms] Google startApp
[ +1 ms] /home/nathan/Android/Sdk/platform-tools/adb -s 192.168.56.101:5555 shell am start -a android.intent.action.RUN -f 0x20000000 --ez enable-background-compilation true --ez enable-dart-profiling true --ez enable-checked-mode true be.nathansamson.bottomnavigationbartheme/be.nathansamson.bottomnavigationbartheme.MainActivity
[ +62 ms] Starting: Intent { act=android.intent.action.RUN flg=0x20000000 cmp=be.nathansamson.bottomnavigationbartheme/.MainActivity (has extras) }
[ ] Waiting for observatory port to be available...
[ +576 ms] I/FlutterActivityDelegate( 2836): onResume setting current activity to this
[ +84 ms] Observatory URL on device: http://127.0.0.1:44191/
[ +10 ms] /home/nathan/Android/Sdk/platform-tools/adb -s 192.168.56.101:5555 forward tcp:8101 tcp:44191
[ +23 ms] Forwarded host port 8101 to device port 44191 for Observatory
[ +13 ms] Connecting to service protocol: http://127.0.0.1:8101/
[ +219 ms] I/flutter ( 2836): NEW APP
[ +55 ms] Successfully connected to service protocol: http://127.0.0.1:8101/
[ +2 ms] getVM: {}
[ +17 ms] getIsolate: {isolateId: isolates/406878495}
[ +2 ms] _flutter.listViews: {isolateId: isolates/406878495}
[ +84 ms] DevFS: Creating new filesystem on the device (null)
[ ] _createDevFS: {fsName: bottom_navigation_bar_theme}
[ +11 ms] I/igationbartheme( 2836): type=1400 audit(0.0:1432): avc: denied { write } for name="cache" dev="sdb3" ino=97817 scontext=u:r:untrusted_app:s0:c512,c768 tcontext=u:object_r:system_data_file:s0 tclass=dir permissive=1
[ +14 ms] DevFS: Created new filesystem on the device (file:///data/user/0/be.nathansamson.bottomnavigationbartheme/cache/bottom_navigation_bar_themeKVTDCO/bottom_navigation_bar_theme/)
[ +1 ms] Updating assets
[ +195 ms] Syncing files to device Google...
[ +4 ms] DevFS: Starting sync from LocalDirectory: '/home/nathan/AndroidStudioProjects/bottom_navigation_bar_theme'
[ ] Scanning project files
[ +3 ms] Scanning package files
[ +139 ms] Scanning asset files
[ ] Scanning for deleted files
[ +10 ms] Compiling dart to kernel with 416 updated files
[ +3 ms] /home/nathan/flutter/bin/cache/dart-sdk/bin/dart /home/nathan/flutter/bin/cache/artifacts/engine/linux-x64/frontend_server.dart.snapshot --sdk-root /home/nathan/flutter/bin/cache/artifacts/engine/common/flutter_patched_sdk/ --incremental --strong --target=flutter --output-dill build/app.dill --packages /home/nathan/AndroidStudioProjects/bottom_navigation_bar_theme/.packages --filesystem-scheme org-dartlang-root
[ +2 ms] D/ ( 2836): HostConnection::get() New Host Connection established 0xdb5a3cc0, tid 2857
[ ] W/ ( 2836): Unrecognized GLES max version string in extensions:
[+2831 ms] Updating files
[ +582 ms] DevFS: Sync finished
[ ] Synced 0.8MB.
[ +2 ms] _flutter.listViews: {isolateId: isolates/406878495}
[ +3 ms] Connected to _flutterView/0xe8a34dcc.
[ ] 🔥 To hot reload changes while running, press "r". To hot restart (and rebuild state), press "R".
[ ] An Observatory debugger and profiler on Google is available at: http://127.0.0.1:8101/
[ ] For a more detailed help message, press "h". To quit, press "q".
[ +154 ms] I/flutter ( 2836): THEME CHANGE
[ +1 ms] I/flutter ( 2836): CHANGED THEME
[ +26 ms] I/flutter ( 2836): NEW APP
[ +58 ms] I/flutter ( 2836): MaterialColor(primary value: Color(0xff2196f3))
[ +114 ms] I/flutter ( 2836): Color(0xfffeea3b)
[ +56 ms] I/flutter ( 2836): MaterialColor(primary value: Color(0xffffeb3b))
[+5835 ms] I/flutter ( 2836): MaterialColor(primary value: Color(0xffffeb3b))
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment