Java Code Examples for com.crashlytics.android.Crashlytics#start()
The following examples show how to use
com.crashlytics.android.Crashlytics#start() .
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: MainActivity.java From Android-Developer-Toolbelt with Apache License 2.0 | 6 votes |
@Override protected void onCreate(Bundle savedInstanceState) { super.onCreate(savedInstanceState); // Do this here so it doesn't start for all threads Crashlytics.start(this); mViewPager.setAdapter(new PagerAdapter(this, getSupportFragmentManager())); //mTabLayout.setDistributeEvenly(true); //mTabLayout.setCustomTabView(R.layout.layout_tab, 0); //mTabLayout.setSelectedIndicatorColors(Color.WHITE); //mTabLayout.setViewPager(mViewPager); mActionBar.setDisplayHomeAsUpEnabled(false); setTitle(R.string.app_name_short); }
Example 2
Source File: FlowApplication.java From flow-android with MIT License | 6 votes |
@Override public void onCreate() { super.onCreate(); Crashlytics.start(this); // Do init here FlowAsyncClient.init(getApplicationContext()); DisplayImageOptions defaultOptions = new DisplayImageOptions.Builder() .cacheInMemory(true) .cacheOnDisc(true) .displayer(new FadeInBitmapDisplayer(500)) .build(); ImageLoaderConfiguration config = new ImageLoaderConfiguration.Builder(getApplicationContext()) .defaultDisplayImageOptions(defaultOptions) .build(); ImageLoader.getInstance().init(config); SharedPreferences preferences = PreferenceManager.getDefaultSharedPreferences(getApplicationContext()); if (preferences != null) { mIsUserLoggedIn = preferences.getBoolean(IS_USER_LOGGED_IN_KEY, false); } getMixpanel(); }
Example 3
Source File: BarterLiApplication.java From barterli_android with Apache License 2.0 | 6 votes |
private void startCrashlytics() { boolean hasValidKey = false; try { Context appContext = this; ApplicationInfo ai = appContext.getPackageManager().getApplicationInfo(appContext.getPackageName(), PackageManager.GET_META_DATA); Bundle bundle = ai.metaData; if (bundle != null) { String apiKey = bundle.getString("com.crashlytics.ApiKey"); hasValidKey = apiKey != null && !apiKey.equals("0000000000000000000000000000000000000000"); } } catch (NameNotFoundException e) { Logger.e(TAG, e, "Unexpected NameNotFound."); } if (hasValidKey) { Crashlytics.start(this); } else { Logger.e(TAG, "Check the crashlytics id in api_keys."); } }
Example 4
Source File: CoreApplication.java From Contacts with MIT License | 5 votes |
private void initBugReport() { if (CoreFlags.ENABLE_BUG_REPORT) { Log.d("CoreApplication", "initBugReport: "); Crashlytics.start(this); } }
Example 5
Source File: MainActivity.java From AutoAP with Apache License 2.0 | 5 votes |
@Override protected void onCreate(Bundle savedInstanceState) { super.onCreate(savedInstanceState); Crashlytics.start(this); setContentView(R.layout.activity_main); mSwitch = (Switch) findViewById(R.id.ap_button); mTetheringImage = (ImageView) findViewById(R.id.tethering_image); mDescription = (TextView) findViewById(R.id.description); ssidEditText = (EditText) findViewById(R.id.ssid_editText); passwordEditText = (EditText) findViewById(R.id.password_editText); spinner = (Spinner) findViewById(R.id.spinner); checkBox = (CheckBox) findViewById(R.id.checkBox); save = (Button) findViewById(R.id.save_button); mWifiAPUtils = new WifiAPUtils(this); mSharedPrefs = this.getSharedPreferences(Constants.PREFS_KEY, Context.MODE_PRIVATE); ssid = mSharedPrefs.getString(Constants.PREFS_SSID, mWifiAPUtils.ssid); securityType = mSharedPrefs.getString(Constants.PREFS_SECURITY, mWifiAPUtils.securityType); password = mSharedPrefs.getString(Constants.PREFS_PASSWORD, mWifiAPUtils.password); setSwitchImageState(); mSwitch.setOnCheckedChangeListener(this); showSpinner(); save.setOnClickListener(this); checkBox.setOnCheckedChangeListener(this); mTetheringImage.setOnClickListener(this); ssidEditText.setText(ssid); passwordEditText.setText(password); }
Example 6
Source File: TapchatApp.java From tapchat-android with Apache License 2.0 | 5 votes |
@Override public void onCreate() { super.onCreate(); sInstance = this; if (!BuildConfig.DEBUG) { Crashlytics.start(this); } mPreferences = PreferenceManager.getDefaultSharedPreferences(this); mObjectGraph = ObjectGraph.create(new TapchatModule(this)); mObjectGraph.inject(this); mBus.register(this); if (mPreferences.getBoolean(PREF_DEBUG, false)) { StrictMode.setThreadPolicy(new StrictMode.ThreadPolicy.Builder() .detectAll() .penaltyLog() .build()); StrictMode.setVmPolicy(new StrictMode.VmPolicy.Builder() .detectAll() .penaltyLog() .build()); } mPusherClient.start(); WebSocketClient.setTrustManagers(mTrustManagers); }
Example 7
Source File: BaseApplication.java From Klyph with MIT License | 5 votes |
private void initBugReport() { if (KlyphFlags.ENABLE_BUG_REPORT) { Crashlytics.start(this); } }
Example 8
Source File: MainActivity.java From Readily with MIT License | 5 votes |
@Override protected void onCreate(Bundle savedInstanceState){ super.onCreate(savedInstanceState); setContentView(R.layout.activity_main); isAnybodyOutThere(this); startService(createCheckerServiceIntent()); Crashlytics.start(this); changeActionBarIcon(); startFileListFragment(); }
Example 9
Source File: BaseApplication.java From KlyphMessenger with MIT License | 5 votes |
private void initBugReport() { if (KlyphFlags.ENABLE_BUG_REPORT) { Crashlytics.start(this); } }
Example 10
Source File: MainApp.java From Kernel-Tuner with GNU General Public License v3.0 | 5 votes |
@Override public void onCreate() { super.onCreate(); context = getApplicationContext(); try { Crashlytics.start(this); } catch(Exception e) { e.printStackTrace(); } app = this; defaultDisplayImageOptions = new DisplayImageOptions.Builder() .cacheInMemory(true) .bitmapConfig(Bitmap.Config.RGB_565) //.showImageOnLoading(R.drawable.ic_action_app) //.showImageOnFail(R.drawable.ic_action_app) //.showImageForEmptyUri(R.drawable.ic_action_app) .build(); ImageLoaderConfiguration config = new ImageLoaderConfiguration.Builder(this) .memoryCacheSizePercentage(13) // default .writeDebugLogs() //.imageDownloader(new SqliteImageLoader(this)) .defaultDisplayImageOptions(defaultDisplayImageOptions) .build(); ImageLoader.getInstance().init(config); System.out.println("App created"); }
Example 11
Source File: EntropyActivity.java From Kernel-Tuner with GNU General Public License v3.0 | 5 votes |
@Override protected void onCreate(Bundle savedInstanceState) { Crashlytics.start(this); super.onCreate(savedInstanceState); setContentView(R.layout.activity_entropy); sbRead = (CircularSeekBar) findViewById(R.id.sbRead); sbWrite = (CircularSeekBar) findViewById(R.id.sbWrite); tvAvailable = (TextView) findViewById(R.id.tvAvailable); tvPoolSize = (TextView) findViewById(R.id.tvPoolSize); tvRead = (TextView) findViewById(R.id.tvRead); tvWrite = (TextView) findViewById(R.id.tvWrite); poolSize = IOHelper.getEntropyPoolSize(); tvPoolSize.setText(poolSize + ""); if (!Constants.ENTROPY_READ_THRESHOLD.exists() || !Constants.ENTROPY_WRITE_THRESHOLD.exists()) { sbRead.setEnabled(false); sbWrite.setEnabled(false); } else { sbRead.setMax(opts.length - 1); sbWrite.setMax(opts.length - 1); int read = IOHelper.getEntropyReadThreshold(); int write = IOHelper.getEntropyWriteThreshold(); tvRead.setText(read + ""); tvWrite.setText(write + ""); sbRead.setProgress(Utility.getIndexForValue(opts, read)); sbWrite.setProgress(Utility.getIndexForValue(opts, write)); sbRead.setOnSeekBarChangeListener(this); sbWrite.setOnSeekBarChangeListener(this); } }
Example 12
Source File: BroadsheetApplication.java From Broadsheet.ie-Android with MIT License | 4 votes |
@Override public void onCreate() { super.onCreate(); // Create global configuration and initialize ImageLoader with this configuration ImageLoaderConfiguration config = new ImageLoaderConfiguration.Builder(getApplicationContext()).build(); ImageLoader.getInstance().init(config); this.posts = new ArrayList<Post>(); Crashlytics.start(this); mGaInstance = GoogleAnalytics.getInstance(this); mGaTracker = mGaInstance.getTracker("UA-5653857-3"); mApp = this; }