Skip to content
This repository has been archived by the owner on Aug 26, 2019. It is now read-only.

Commit

Permalink
完善下载界面
Browse files Browse the repository at this point in the history
  • Loading branch information
seven332 committed Aug 22, 2014
1 parent da90150 commit 5822e58
Show file tree
Hide file tree
Showing 48 changed files with 1,226 additions and 1,226 deletions.
6 changes: 3 additions & 3 deletions AndroidManifest.xml
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
package="com.hippo.ehviewer"
android:versionCode="20"
android:versionName="0.5.0" >
android:versionName="0.5.4" >

<uses-sdk
android:minSdkVersion="14"
Expand All @@ -32,9 +32,9 @@
android:name=".AppContext"
android:allowBackup="true"
android:hardwareAccelerated="true"
android:largeHeap="true"
android:icon="@drawable/ic_launcher"
android:label="@string/app_name"
android:largeHeap="false"
android:theme="@style/AppTheme.Normal" >

<activity
Expand Down Expand Up @@ -114,7 +114,7 @@
android:theme="@style/AppTheme.ListActivity" >
<meta-data
android:name="android.support.PARENT_ACTIVITY"
android:value="com.hippo.ehviewer.activity.MangaListActivity" />
android:value=".ui.GalleryListActivity" />
</activity>

<service
Expand Down
3 changes: 1 addition & 2 deletions res/layout/download.xml
Original file line number Diff line number Diff line change
Expand Up @@ -25,8 +25,7 @@
android:layout_height="fill_parent"
android:clipToPadding="false"
android:divider="@android:color/transparent"
android:dividerHeight="0dp"
android:fitsSystemWindows="true" >
android:dividerHeight="0dp" >
</ListView>

</LinearLayout>
63 changes: 0 additions & 63 deletions res/layout/download_item.xml

This file was deleted.

157 changes: 157 additions & 0 deletions res/layout/download_list_item.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,157 @@
<?xml version="1.0" encoding="utf-8"?>
<!--
Copyright (C) 2014 Hippo Seven
Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.
-->
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
android:layout_width="match_parent"
android:layout_height="wrap_content" >

<RelativeLayout
android:id="@+id/card_view"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_marginBottom="4dp"
android:layout_marginLeft="8dp"
android:layout_marginRight="8dp"
android:layout_marginTop="4dp" >

<com.hippo.ehviewer.widget.LoadImageView
android:id="@+id/thumb"
android:layout_width="@dimen/list_thumb_width"
android:layout_height="@dimen/list_thumb_height" />

<TextView
android:id="@+id/title"
style="@style/CardTitle"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_alignParentTop="true"
android:layout_marginLeft="16dp"
android:layout_marginRight="8dp"
android:layout_marginTop="8dp"
android:layout_toRightOf="@id/thumb" />

<ProgressBar
android:id="@+id/progress_bar"
style="?android:attr/progressBarStyleHorizontal"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_below="@id/title"
android:layout_marginLeft="16dp"
android:layout_marginRight="16dp"
android:layout_marginTop="10dp"
android:layout_toRightOf="@id/thumb" />

<TextView
android:id="@+id/text_left"
style="@style/CardMessage"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_below="@id/progress_bar"
android:layout_marginLeft="16dp"
android:layout_marginTop="10dp"
android:layout_toRightOf="@id/thumb" />

<TextView
android:id="@+id/text_right"
style="@style/CardMessage"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_alignParentRight="true"
android:layout_below="@id/progress_bar"
android:layout_marginRight="16dp"
android:layout_marginTop="10dp" />

<TableLayout
android:id="@+id/buttons"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_marginTop="8dp"
android:layout_below="@id/thumb" >

<TableRow
android:layout_width="match_parent"
android:layout_height="wrap_content" >

<TextView
android:id="@+id/read"
style="@style/EmbedButton"
android:layout_width="0dp"
android:layout_height="wrap_content"
android:layout_gravity="center"
android:layout_weight="1"
android:gravity="center"
android:text="@string/read" />

<TextView
android:id="@+id/action"
style="@style/EmbedButton"
android:layout_width="0dp"
android:layout_height="wrap_content"
android:layout_gravity="center"
android:layout_weight="1"
android:gravity="center" />

</TableRow>

<TableRow
android:layout_width="match_parent"
android:layout_height="wrap_content" >

<TextView
android:id="@+id/delete1"
style="@style/EmbedButton"
android:layout_width="0dp"
android:layout_height="wrap_content"
android:layout_gravity="center"
android:layout_weight="1"
android:gravity="center"
android:textColor="@color/warning_red"
android:text="@string/delete" />

<TextView
android:id="@+id/delete2"
style="@style/EmbedButton"
android:layout_width="0dp"
android:layout_height="wrap_content"
android:layout_gravity="center"
android:layout_weight="1"
android:gravity="center"
android:textColor="@color/warning_red"
android:text="@string/delete2" />

</TableRow>

<TableRow
android:layout_width="match_parent"
android:layout_height="wrap_content" >

<TextView
android:id="@+id/detail"
style="@style/EmbedButton"
android:layout_width="0dp"
android:layout_height="wrap_content"
android:layout_gravity="center"
android:layout_weight="1"
android:gravity="center"
android:text="@string/detail" />

</TableRow>

</TableLayout>

</RelativeLayout>

</LinearLayout>
2 changes: 1 addition & 1 deletion res/layout/gallery_list_detail_item.xml
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@
android:id="@+id/thumb"
android:layout_width="@dimen/list_thumb_width"
android:layout_height="@dimen/list_thumb_height" />

<TextView
android:id="@+id/title"
style="@style/CardTitle"
Expand Down
4 changes: 4 additions & 0 deletions res/values-zh-rCN/strings.xml
Original file line number Diff line number Diff line change
Expand Up @@ -362,6 +362,9 @@
<string name="rating0">…</string>

<!-- Util -->
<string name="attention">注意</string>
<string name="start">开始</string>
<string name="stop">停止</string>
<string name="invalid_input">无效的输入</string>
<string name="never_show">不再显示</string>
<string name="retry">重试</string>
Expand Down Expand Up @@ -393,6 +396,7 @@
<string name="some_page">第 %d 页</string>
<string name="_default">默认</string>
<string name="delete">删除</string>
<string name="delete2">删除(包括图片)</string>
<string name="move">移动</string>
<string name="list">列表</string>
<string name="homepage">首页</string>
Expand Down
4 changes: 2 additions & 2 deletions res/values/colors.xml
Original file line number Diff line number Diff line change
Expand Up @@ -50,14 +50,14 @@

<color name="detail_title_secondary">#ff777777</color>



<color name="btn_bg_color_default">#ff2196f3</color>

<color name="btn_white_default">#fff0f0f0</color>

<color name="divider">#22000000</color>

<color name="warning_red">#ffe51c23</color>

<color name="background_light">#fffafafa</color>
<color name="background_dark">#ff212121</color>
<color name="background_little_light">#ffe5e5e5</color>
Expand Down
16 changes: 14 additions & 2 deletions res/values/styles.xml
Original file line number Diff line number Diff line change
Expand Up @@ -106,7 +106,7 @@
<item name="android:maxHeight">16dip</item>
</style>

<style name="ProgressBar.Large">
<style name="ProgressBar.Large">
<item name="android:indeterminateDrawable">@drawable/progress_large</item>
<item name="android:minWidth">76dip</item>
<item name="android:maxWidth">76dip</item>
Expand Down Expand Up @@ -172,7 +172,7 @@

<style name="TextAppearance.SearchCategory">
<item name="@android:textColor">@color/primary_text_light</item>
<item name="@android:textStyle">bold</item>
<item name="android:textSize">@dimen/text_little_large</item>
<item name="@android:singleLine">true</item>
</style>

Expand All @@ -190,4 +190,16 @@
<item name="@android:fontFamily">sans-serif-condensed</item>
</style>

<style name="TextAppearance.EmbedButton">
<item name="@android:textSize">@dimen/text_large</item>
<item name="@android:textStyle">bold</item>
<item name="@android:singleLine">true</item>
</style>

<style name="EmbedButton">
<item name="@android:textAppearance">@style/TextAppearance.EmbedButton</item>
<item name="@android:minHeight">48dp</item>
<item name="@android:minWidth">32dp</item>
</style>

</resources>
2 changes: 0 additions & 2 deletions src/com/hippo/ehviewer/AppContext.java
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,6 @@
import com.hippo.ehviewer.ehclient.ExDownloaderManager;
import com.hippo.ehviewer.util.Config;
import com.hippo.ehviewer.util.Crash;
import com.hippo.ehviewer.util.Download;
import com.hippo.ehviewer.util.Favorite;
import com.hippo.ehviewer.util.Ui;
import com.hippo.ehviewer.widget.MaterialToast;
Expand Down Expand Up @@ -64,7 +63,6 @@ public void onCreate() {
Ui.init(this);
Crash.init(this);
EhClient.createInstance(this);
Download.init(this);
Favorite.init(this);
Data.createInstance(this);
ExDownloaderManager.createInstance();
Expand Down
2 changes: 1 addition & 1 deletion src/com/hippo/ehviewer/StartActivity.java
Original file line number Diff line number Diff line change
Expand Up @@ -39,6 +39,7 @@
import com.hippo.ehviewer.widget.DialogBuilder;

public class StartActivity extends Activity {
private static final String TAG = StartActivity.class.getSimpleName();

private static final int CHECK_WARING = 0;
private static final int CHECK_ANALYTICS = 1;
Expand Down Expand Up @@ -183,7 +184,6 @@ public void onClick(View v) {
@Override
public void onCreate(Bundle savedInstanceState) {
super.onCreate(savedInstanceState);

View wellcome = new View(this);
wellcome.setBackgroundDrawable(getResources().getDrawable(R.drawable.welcome));
setContentView(wellcome);
Expand Down
Loading

0 comments on commit 5822e58

Please sign in to comment.