草庐IT

supports-screen

全部标签

android - SwipeRefreshLayout 从 support21 force 到旧样式

我刚刚更新了支持库-新的SwipeRefreshLayout不是我的口味。有没有办法恢复旧样式?仍然有setColor方法——这有点奇怪——它们似乎不再有用了。我真的希望有旧的风格我不必坚持旧的图书馆。 最佳答案 我实际上也必须这样做-我需要带有顶部水平线指示器的“全息”SwipeRefreshLayout,而不是下拉旋转箭头指示器。如果您想要旧的SwipeRefreshLayout,您实际上可以在项目中引用旧版本的android支持库;例如compile'com.android.support:support-v4:21.0.+'

android - 为什么以编程方式调用电话会给出错误消息 "Internet Calling not Supported"?

这是我的代码:publicStringa_number;@OverrideprotectedvoidonCreate(BundlesavedInstanceState){super.onCreate(savedInstanceState);setContentView(R.layout.activity_make_the_call);//callButton=(ImageButton)findViewById(R.id.call_button);aCall=(TextView)findViewById(R.id.number_a);a_number=aCall.getText().to

android - 多个dex文件用Gradle定义Landroid/support/v4/accessibilityservice/AccessibilityServiceInfoCompat

当我运行./gradlewassembleDebug时,我得到::app:dexDebugFAILEDFAILURE:Buildfailedwithanexception.*Whatwentwrong:Executionfailedfortask':app:dexDebug'.>com.android.ide.common.internal.LoggedErrorException:Failedtoruncommand:/home/grub/Main/android-sdk-linux/build-tools/19.1.0/dx--dex--num-threads=4--output合

android - Java.lang.ClassCastException : Android. support.v7.widget.ContentFrameLayout 无法转换为Android.support.v7.widget.ContentFrameLayout

有时我在安装我的Android应用程序时会遇到以下异常,但这并不总是可重现的。java.lang.ClassCastException:android.support.v7.widget.ContentFrameLayoutcannotbecasttoandroid.support.v7.widget.ContentFrameLayout我在我的Android应用程序上使用multidex,我阅读了thisquestion关于Samsung设备在multidex实现方面存在错误,但这发生在运行5.1的LGG3和运行6.0的HTCA9上。任何人都知道为什么会随机发生这种情况,我该如何解决

android - 在 Activity 中保持屏幕开启 - 不适用于 FLAG_KEEP_SCREEN_ON

很长一段时间我都认为我知道如何阻止屏幕进入休眠模式,我只是在我的Activity中使用了这段代码:getWindow().addFlags(WindowManager.LayoutParams.FLAG_KEEP_SCREEN_ON);但是,我意识到这仅在我的手机处于“开发者模式”时有效,即当启用/选中USB调试(设置-->开发者选项-->USB调试)时。然后上面的代码确实停止了屏幕/设备进入休眠状态。如果不检查调试,那么我的屏幕就会进入休眠状态,就像没有明天一样。我在我的设备上运行Android4.04,并且android:minSdkVersion="12"android:targ

android - 模拟器 : WARNING: Classic qemu does not support SMP. 配置文件中的 hw.cpu.ncore 选项被忽略

我在启动模拟器时遇到了这个错误。有什么建议吗?模拟器警告:ClassicqemudoesnotsupportSMP.Thehw.cpu.ncoreoptionfromyourconfigfileisignored.CouldnotloadfuncglBindFramebufferCouldnotloadfuncglGenFramebuffersCouldnotloadfuncglFramebufferTexture2DCouldnotloadfuncglCheckFramebufferStatusCouldnotloadfuncglDeleteFramebuffersCouldnotl

android - 多个dex文件在android studio中定义Landroid/support/v4/

我可以与许多库集成(添加和工作)。但是对于ActionBarSherlock库,我有很多问题。第一期是热门期Multipledexfilesdefine,我知道duplicatedandroid-support-v4.jar导致了它,但我现在无法解决这个问题:Error:Executionfailedfortask':fitness:dexDebug'.ErrorCode:2Output:UNEXPECTEDTOP-LEVELEXCEPTION:com.android.dex.DexException:MultipledexfilesdefineLandroid/support/v4/

android - 无法执行 dex : Multiple dex files define Landroid/support/v7/appcompat

当我尝试运行我的项目时遇到异常:[2014-09-2911:56:32-DexLoader]Unabletoexecutedex:MultipledexfilesdefineLandroid/support/v7/appcompat/R$anim;[2014-09-2911:56:32-PageViewers]ConversiontoDalvikformatfailed:Unabletoexecutedex:MultipledexfilesdefineLandroid/support/v7/appcompat/R$anim; 最佳答案

java.lang.NoClassDefFoundError : Failed resolution of: Landroid/support/v4/graphics/drawable/DrawableWrapper; 错误

应用程序正在运行,但当打开警报对话框时,我们会收到此错误。已经4天了,没有找到任何解决方案。03-0616:05:23.3555505-5505/com.boltt.healthE/UncaughtException:java.lang.NoClassDefFoundError:Failedresolutionof:Landroid/support/v4/graphics/drawable/DrawableWrapper;atandroid.support.v7.widget.DrawableUtils.canSafelyMutateDrawable(DrawableUtils.jav

android - 如何在 Android 上的 Chrome 上调试 "add to home screen"?

我正在尝试将内部Web应用程序添加到Android设备的主屏幕以进行测试。这应该是一个真正的chrome-wrappedweb应用程序,具有全屏、自定义图标等。但它不起作用,而且我看不到任何调试/解决问题的方法。list已添加并链接。服务器位于IP地址、非标准端口和自签名SSL证书上-如果这些细节是问题所在,可以吗?如能提供帮助,我们将不胜感激! 最佳答案 您可以通过多种方法来测试您的配置是否正确。使用MounirLamouri的ManifestValidator看看有没有明显的错误检查Chrome开发工具。Chrome将始终尝试下