Java Code Examples for com.squareup.leakcanary.LeakCanary#isInAnalyzerProcess()
The following examples show how to use
com.squareup.leakcanary.LeakCanary#isInAnalyzerProcess() .
You can vote up the ones you like or vote down the ones you don't like,
and go to the original project or source file by following the links above each example. You may check out the related API usage on the sidebar.
Example 1
Source File: SampleApplication.java From mosby with Apache License 2.0 | 6 votes |
@Override public void onCreate() { super.onCreate(); if (LeakCanary.isInAnalyzerProcess(this)) { // This process is dedicated to LeakCanary for heap analysis. // You should not init your app in this process. return; } refWatcher = LeakCanary.install(this); /* ActivityMvpViewStateDelegateImpl.DEBUG = true; FragmentMvpViewStateDelegateImpl.DEBUG = true; ViewGroupMvpViewStateDelegateImpl.DEBUG = true; ActivityMvpDelegateImpl.DEBUG = true; FragmentMvpDelegateImpl.DEBUG=true; ViewGroupMvpDelegateImpl.DEBUG = true; */ }
Example 2
Source File: MyApp.java From RxJava-Android-Samples with Apache License 2.0 | 6 votes |
@Override public void onCreate() { super.onCreate(); if (LeakCanary.isInAnalyzerProcess(this)) { // This process is dedicated to LeakCanary for heap analysis. // You should not init your app in this process. return; } _instance = (MyApp) getApplicationContext(); _refWatcher = LeakCanary.install(this); // for better RxJava debugging //RxJavaHooks.enableAssemblyTracking(); // Initialize Volley MyVolley.init(this); Timber.plant(new Timber.DebugTree()); }
Example 3
Source File: TestModuleApplication.java From JD-Test with Apache License 2.0 | 6 votes |
@Override public void onCreate() { super.onCreate(); if (LeakCanary.isInAnalyzerProcess(this)) { return; } if(CommonConfig.DEBUG){ LeakCanary.install(this); ARouter.openLog(); // 打印日志 ARouter.openDebug(); // 开启调试模式(如果在InstantRun模式下运行,必须开启调试模式!线上版本需要关闭,否则有安全风险) } ARouter.init(this); //CrashReport.initCrashReport(getApplicationContext(), "93f0e37549", CommonConfig.DEBUG); Fresco.initialize(this); GlobalAppComponent.init(this); }
Example 4
Source File: BitmaskApp.java From bitmask_android with GNU General Public License v3.0 | 6 votes |
@Override public void onCreate() { super.onCreate(); if (LeakCanary.isInAnalyzerProcess(this)) { // This process is dedicated to LeakCanary for heap analysis. // You should not init your app in this process. return; } refWatcher = LeakCanary.install(this); // Normal app init code...*/ PRNGFixes.apply(); SharedPreferences preferences = getSharedPreferences(SHARED_PREFERENCES, MODE_PRIVATE); providerObservable = ProviderObservable.getInstance(); providerObservable.updateProvider(getSavedProviderFromSharedPreferences(preferences)); EipSetupObserver.init(this, preferences); AppCompatDelegate.setCompatVectorFromResourcesEnabled(true); TetheringStateManager.getInstance().init(this); }
Example 5
Source File: TkApplication.java From TwinklingRefreshLayout with Apache License 2.0 | 6 votes |
@Override public void onCreate() { super.onCreate(); appContext = this; if (LeakCanary.isInAnalyzerProcess(this)) { return; } enabledStrictMode(); LeakCanary.install(this); StrictMode.setThreadPolicy(new StrictMode.ThreadPolicy.Builder().detectAll().penaltyDeath().build()); StrictMode.setVmPolicy(new StrictMode.VmPolicy.Builder().detectAll().penaltyDeath().build()); BlockCanary.install(this,new AppBlockCanaryContext()).start(); // TwinklingRefreshLayout.setDefaultHeader(SinaRefreshView.class.getName()); // TwinklingRefreshLayout.setDefaultFooter(BallPulseView.class.getName()); }
Example 6
Source File: BaseApplication.java From NewFastFrame with Apache License 2.0 | 6 votes |
@Override public void onCreate() { super.onCreate(); if (LeakCanary.isInAnalyzerProcess(this)) { // This process is dedicated to LeakCanary for heap analysis. // You should not init your app in this process. return; } LeakCanary.install(this); instance = this; initDagger(); initFont(); initUM(); initScreenAdapt(); initBugly(); initKeepLive(); applicationDelegate.onCreate(this); }
Example 7
Source File: LeakCanaryApplication.java From Highlight with Apache License 2.0 | 5 votes |
@Override public void onCreate() { super.onCreate(); if (LeakCanary.isInAnalyzerProcess(this)) { // This process is dedicated to LeakCanary for heap analysis. // You should not init your app in this process. return; } LeakCanary.install(this); }
Example 8
Source File: ExampleViewModelApplication.java From valifi with Apache License 2.0 | 5 votes |
@Override public void onCreate() { super.onCreate(); if (LeakCanary.isInAnalyzerProcess(this)) { // This process is dedicated to LeakCanary for heap analysis. // You should not init your app in this process. return; } LeakCanary.install(this); ValiFi.install(this); }
Example 9
Source File: SampleApplication.java From mosby with Apache License 2.0 | 5 votes |
@Override public void onCreate() { super.onCreate(); if (LeakCanary.isInAnalyzerProcess(this)) { // This process is dedicated to LeakCanary for heap analysis. // You should not init your app in this process. return; } refWatcher = LeakCanary.install(this); Timber.d("Starting Application"); }
Example 10
Source File: App.java From android-open-framework-analysis with Apache License 2.0 | 5 votes |
@Override public void onCreate() { super.onCreate(); if (LeakCanary.isInAnalyzerProcess(this)) { return; } refWatcher = LeakCanary.install(this); }
Example 11
Source File: AppLifecyclesImpl.java From Hands-Chopping with Apache License 2.0 | 5 votes |
@Override public void onCreate(Application application) { if (LeakCanary.isInAnalyzerProcess(application)) { // This process is dedicated to LeakCanary for heap analysis. // You should not init your app in this process. return; } //使用 RetrofitUrlManager 切换 BaseUrl //RetrofitUrlManager.getInstance().putDomain(STEAM_DOMAIN_NAME, STEAM_DOMAIN); //当所有模块集成到宿主 App 时, 在 App 中已经执行了以下代码 if (BuildConfig.IS_BUILD_MODULE) { //leakCanary内存泄露检查 ArmsUtils.obtainAppComponentFromContext(application).extras().put(RefWatcher.class.getName(), BuildConfig.USE_CANARY ? LeakCanary.install(application) : RefWatcher.DISABLED); } }
Example 12
Source File: GirlApplication.java From Girls with Apache License 2.0 | 5 votes |
@Override public void onCreate() { super.onCreate(); if (LeakCanary.isInAnalyzerProcess(this)) { // This process is dedicated to LeakCanary for heap analysis. // You should not init your app in this process. return; } LeakCanary.install(this); initImageLoader(getApplicationContext()); }
Example 13
Source File: BaseApplication.java From chat-window-android with MIT License | 5 votes |
@Override public void onCreate() { super.onCreate(); if (LeakCanary.isInAnalyzerProcess(this)) { return; } LeakCanary.install(this); }
Example 14
Source File: DemoApplication.java From CameraCompat with MIT License | 5 votes |
@Override public void onCreate() { super.onCreate(); if (LeakCanary.isInAnalyzerProcess(this)) { return; } LeakCanary.install(this); }
Example 15
Source File: App.java From Cashew with Apache License 2.0 | 5 votes |
@Override public void onCreate() { super.onCreate(); intDIR(); appContext = getApplicationContext(); if (LeakCanary.isInAnalyzerProcess(this)) { // This process is dedicated to LeakCanary for heap analysis. // You should not init your app in this process. return; } LeakCanary.install(this); }
Example 16
Source File: App.java From WaveLineView with Apache License 2.0 | 5 votes |
@Override public void onCreate() { super.onCreate(); if (LeakCanary.isInAnalyzerProcess(this)) { return; } LeakCanary.install(this); }
Example 17
Source File: App.java From BluetoothChatting with Apache License 2.0 | 5 votes |
@Override public void onCreate() { super.onCreate(); if (LeakCanary.isInAnalyzerProcess(this)) { // This process is dedicated to LeakCanary for heap analysis. // You should not init your app in this process. return; } LeakCanary.install(this); // Normal app init code... }
Example 18
Source File: WanAndroidApplication.java From WanAndroid with MIT License | 5 votes |
@Override public void onCreate() { super.onCreate(); CrashReport.initCrashReport(this); mApplication = this; ObjectBox.init(this); AccountManager.getInstance().init(); if (!LeakCanary.isInAnalyzerProcess(this)) { LeakCanary.install(this); } initSonic(); CrashHandler crashHandler = CrashHandler.getInstance(); crashHandler.init(this); Thread.setDefaultUncaughtExceptionHandler(crashHandler); }
Example 19
Source File: App.java From NewbieGuide with Apache License 2.0 | 5 votes |
@Override public void onCreate() { super.onCreate(); instance = this; if (LeakCanary.isInAnalyzerProcess(this)) { // This process is dedicated to LeakCanary for heap analysis. // You should not init your app in this process. return; } refWatcher = LeakCanary.install(this); // Normal app init code... }
Example 20
Source File: App.java From WanAndroid with Apache License 2.0 | 4 votes |
private void initLeakCanary() { if (!LeakCanary.isInAnalyzerProcess(this)) LeakCanary.install(this); }