06-1800:50:12.54718537-18537/com.perqin.copyshare E/AndroidRuntime: FATAL EXCEPTION: main Process: com.perqin.copyshare, PID: 18537 java.lang.RuntimeException: Unable to start activity ComponentInfo{com.perqin.copyshare/com.perqin.copyshare.SettingsActivity}: android.view.InflateException: Binary XML file line #25: Binary XML file line #1: Error inflating class x at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:2762) at android.app.ActivityThread.handleLaunchActivity(ActivityThread.java:2848) at android.app.ActivityThread.-wrap12(ActivityThread.java) at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1552) at android.os.Handler.dispatchMessage(Handler.java:102) at android.os.Looper.loop(Looper.java:154) at android.app.ActivityThread.main(ActivityThread.java:6324) at java.lang.reflect.Method.invoke(Native Method) at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:886) at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:776) Caused by: android.view.InflateException: Binary XML file line #25: Binary XML file line #1: Error inflating class x Caused by: android.view.InflateException: Binary XML file line #1: Error inflating class x Caused by: java.lang.ClassNotFoundException: Didn't find class"android.view.x" on path: DexPathList[[zipfile "/data/app/com.perqin.copyshare-1/base.apk"],nativeLibraryDirectories=[/data/app/com.perqin.copyshare-1/lib/arm64, /system/lib64, /vendor/lib64]] at dalvik.system.BaseDexClassLoader.findClass(BaseDexClassLoader.java:56) at java.lang.ClassLoader.loadClass(ClassLoader.java:380) at java.lang.ClassLoader.loadClass(ClassLoader.java:312) at android.view.LayoutInflater.createView(LayoutInflater.java:609) at android.view.LayoutInflater.onCreateView(LayoutInflater.java:700) at com.android.internal.policy.PhoneLayoutInflater.onCreateView(PhoneLayoutInflater.java:68) at android.view.LayoutInflater.onCreateView(LayoutInflater.java:717) at android.view.LayoutInflater.createViewFromTag(LayoutInflater.java:785) at android.view.LayoutInflater.parseInclude(LayoutInflater.java:964) at android.view.LayoutInflater.rInflate(LayoutInflater.java:854) at android.view.LayoutInflater.rInflateChildren(LayoutInflater.java:821) at android.view.LayoutInflater.inflate(LayoutInflater.java:518) at android.view.LayoutInflater.inflate(LayoutInflater.java:426) at android.view.LayoutInflater.inflate(LayoutInflater.java:377) at android.support.v7.app.AppCompatDelegateImplV9.createSubDecor(Unknown Source) at android.support.v7.app.AppCompatDelegateImplV9.ensureSubDecor(Unknown Source) at android.support.v7.app.AppCompatDelegateImplV9.onCreate(Unknown Source) findViewById onConfigurationChanged setContentView setContentView onSubDecorInstalled onPanelClosed onMenuItemSelected onMenuModeChange startSupportActionModeFromWindow onKeyShortcut dispatchKeyEvent shouldInheritContext callActivityOnCreateView openPanel initializePanelDecor reopenMenu closePanel callOnPanelClosed findMenuPanel getPanelState performPanelShortcut at android.support.v7.app.AppCompatActivity.findViewById(Unknown Source) at android.app.Activity$HostCallbacks.onFindViewById(Activity.java:7273) at android.app.BackStackRecord.configureTransitions(BackStackRecord.java:1303) at android.app.BackStackRecord.beginTransition(BackStackRecord.java:1024) at android.app.BackStackRecord.run(BackStackRecord.java:729) at android.app.FragmentManagerImpl.execPendingActions(FragmentManager.java:1578) at android.app.FragmentController.execPendingActions(FragmentController.java:371) at android.app.Activity.performStart(Activity.java:6776) at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:2725) at android.app.ActivityThread.handleLaunchActivity(ActivityThread.java:2848) at android.app.ActivityThread.-wrap12(ActivityThread.java) at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1552) at android.os.Handler.dispatchMessage(Handler.java:102) at android.os.Looper.loop(Looper.java:154) at android.app.ActivityThread.main(ActivityThread.java:6324) at java.lang.reflect.Method.invoke(Native Method) at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:886) at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:776) 06-1800:50:12.54718537-18537/com.perqin.copyshare D/AppTracker: App Event: crash 06-1800:50:12.55818537-18537/com.perqin.copyshare I/Process: Sending signal. PID: 18537 SIG: 9
if (!a.hasValue(R.styleable.AppCompatTheme_windowActionBar)) { a.recycle(); thrownewIllegalStateException( "You need to use a Theme.AppCompat theme (or descendant) with this activity."); }
if (a.getBoolean(R.styleable.AppCompatTheme_windowNoTitle, false)) { requestWindowFeature(Window.FEATURE_NO_TITLE); } elseif (a.getBoolean(R.styleable.AppCompatTheme_windowActionBar, false)) { // Don't allow an action bar if there is no title. requestWindowFeature(FEATURE_SUPPORT_ACTION_BAR); } if (a.getBoolean(R.styleable.AppCompatTheme_windowActionBarOverlay, false)) { requestWindowFeature(FEATURE_SUPPORT_ACTION_BAR_OVERLAY); } if (a.getBoolean(R.styleable.AppCompatTheme_windowActionModeOverlay, false)) { requestWindowFeature(FEATURE_ACTION_MODE_OVERLAY); } mIsFloating = a.getBoolean(R.styleable.AppCompatTheme_android_windowIsFloating, false); a.recycle();
// Now let's make sure that the Window has installed its decor by retrieving it mWindow.getDecorView();
if (!mWindowNoTitle) { if (mIsFloating) { // If we're floating, inflate the dialog title decor subDecor = (ViewGroup) inflater.inflate( R.layout.abc_dialog_title_material, null);
// Floating windows can never have an action bar, reset the flags mHasActionBar = mOverlayActionBar = false; } elseif (mHasActionBar) { /** * This needs some explanation. As we can not use the android:theme attribute * pre-L, we emulate it by manually creating a LayoutInflater using a * ContextThemeWrapper pointing to actionBarTheme. */ TypedValueoutValue=newTypedValue(); mContext.getTheme().resolveAttribute(R.attr.actionBarTheme, outValue, true);
// Now inflate the view using the themed context and set it as the content view subDecor = (ViewGroup) LayoutInflater.from(themedContext) .inflate(R.layout.abc_screen_toolbar, null);
/** * Propagate features to DecorContentParent */ if (mOverlayActionBar) { mDecorContentParent.initFeature(FEATURE_SUPPORT_ACTION_BAR_OVERLAY); } if (mFeatureProgress) { mDecorContentParent.initFeature(Window.FEATURE_PROGRESS); } if (mFeatureIndeterminateProgress) { mDecorContentParent.initFeature(Window.FEATURE_INDETERMINATE_PROGRESS); } } } else { if (mOverlayActionMode) { subDecor = (ViewGroup) inflater.inflate( R.layout.abc_screen_simple_overlay_action_mode, null); } else { subDecor = (ViewGroup) inflater.inflate(R.layout.abc_screen_simple, null); }
if (Build.VERSION.SDK_INT >= 21) { // If we're running on L or above, we can rely on ViewCompat's // setOnApplyWindowInsetsListener ViewCompat.setOnApplyWindowInsetsListener(subDecor, newOnApplyWindowInsetsListener() { @Override public WindowInsetsCompat onApplyWindowInsets(View v, WindowInsetsCompat insets) { finalinttop= insets.getSystemWindowInsetTop(); finalintnewTop= updateStatusGuard(top);
finalViewGroupwindowContentView= (ViewGroup) mWindow.findViewById(android.R.id.content); if (windowContentView != null) { // There might be Views already added to the Window's content view so we need to // migrate them to our content view while (windowContentView.getChildCount() > 0) { finalViewchild= windowContentView.getChildAt(0); windowContentView.removeViewAt(0); contentView.addView(child); }
// Change our content FrameLayout to use the android.R.id.content id. // Useful for fragments. windowContentView.setId(View.NO_ID); contentView.setId(android.R.id.content);
// The decorContent may have a foreground drawable set (windowContentOverlay). // Remove this as we handle it ourselves if (windowContentView instanceof FrameLayout) { ((FrameLayout) windowContentView).setForeground(null); } }
// Now set the Window's content view with the decor mWindow.setContentView(subDecor);