当我启动我的应用程序时,我会在启动闪屏之前看到白屏几秒钟.
我想知道我的应用程序的大小是否会影响它(它是17.7MB).或者是因为我的测试设备是旧的(HTC Desire HD)并且有太多数据被破坏了?
或者这是正常的行为?或者问题可能在我的代码中,这是在...
部分清单:
<activity android:name=".SplashView"
android:noHistory="true"
android:screenOrientation="portrait"
android:label="@string/app_name">
<intent-filter>
<action android:name="android.intent.action.MAIN" />
<category android:name="android.intent.category.LAUNCHER" />
</intent-filter>
</activity>
<activity
android:name=".MainActivity"
android:label="@string/app_name"
android:screenOrientation="portrait"
android:windowSoftInputMode="adjustPan"
android:configChanges="orientation" >
<intent-filter >
<category android:name="android.intent.category.DEFAULT" />
</intent-filter>
</activity>
Run Code Online (Sandbox Code Playgroud)
飞溅活动:
public class SplashView extends SherlockActivity {
private final int SPLASH_DISPLAY_LENGHT = 1000;
@Override
protected void onCreate(Bundle savedInstanceState) {
super.onCreate(savedInstanceState);
getSupportActionBar().hide();
setContentView(R.layout.splash_view);
try {
RefreshRatingsTask urt = new RefreshRatingsTask();
urt.execute();
} catch (Exception e) {
// ignore
}
new Handler().postDelayed(new Runnable() {
@Override
public void run() …Run Code Online (Sandbox Code Playgroud) 我是javascript新手。
我想从base64创建SVG。我正在尝试http://jsfiddle.net/XTUmV/28/, 但没有显示任何内容。
var image="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAUAAAAFCAYAAACNbyblAAAAHElEQVQI12P4//8/w38GIAXDIBKE0DHxgljNBAAO9TXL0Y4OHwAAAABJRU5ErkJggg==";
var svgimg = document.createElementNS("http://www.w3.org/2000/svg", "image");
svgimg.setAttributeNS("http://www.w3.org/1999/xlink", 'xlink:href', image);
document.getElementById("mySvg").appendChild(svgimg);
Run Code Online (Sandbox Code Playgroud)
和html:
<svg id="mySvg" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink"></svg>
Run Code Online (Sandbox Code Playgroud)
base64应该是正确的,因为我从此http://jsfiddle.net/MxHPq/示例中获取了它
我在做一些愚蠢的事情或只是错误的方法?
谢谢