Embedded GigaGet download manager. First try.
This commit is contained in:
parent
f08b1224c9
commit
4bae12aa55
58 changed files with 3121 additions and 40 deletions
18
app/src/main/res/layout/activity_downloader.xml
Normal file
18
app/src/main/res/layout/activity_downloader.xml
Normal file
|
|
@ -0,0 +1,18 @@
|
|||
<RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent"
|
||||
android:orientation="vertical">
|
||||
|
||||
<FrameLayout
|
||||
android:id="@+id/frame"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent"/>
|
||||
|
||||
<FrameLayout
|
||||
android:id="@+id/nav"
|
||||
android:layout_gravity="left"
|
||||
android:layout_width="240dp"
|
||||
android:layout_height="match_parent">
|
||||
</FrameLayout>
|
||||
|
||||
</RelativeLayout>
|
||||
111
app/src/main/res/layout/dialog_url.xml
Normal file
111
app/src/main/res/layout/dialog_url.xml
Normal file
|
|
@ -0,0 +1,111 @@
|
|||
<LinearLayout
|
||||
xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:orientation="vertical">
|
||||
|
||||
<android.support.v7.widget.Toolbar
|
||||
xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:id="@+id/toolbar"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:background="?attr/actionBarItemBackground"/>
|
||||
|
||||
<View
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="4dp"
|
||||
android:background="@drawable/action_shadow"/>
|
||||
|
||||
<LinearLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginLeft="24dp"
|
||||
android:layout_marginRight="24dp"
|
||||
android:layout_marginTop="9dp"
|
||||
android:layout_marginBottom="24dp"
|
||||
android:gravity="center_vertical"
|
||||
android:orientation="vertical">
|
||||
|
||||
<TextView
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="@string/msg_url"/>
|
||||
|
||||
<EditText
|
||||
android:id="@+id/url"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:singleLine="true"
|
||||
android:ems="10"/>
|
||||
|
||||
</LinearLayout>
|
||||
|
||||
|
||||
<LinearLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginLeft="24dp"
|
||||
android:layout_marginRight="24dp"
|
||||
android:layout_marginBottom="24dp"
|
||||
android:gravity="center_vertical"
|
||||
android:orientation="vertical">
|
||||
|
||||
<TextView
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="@string/msg_name"/>
|
||||
|
||||
<EditText
|
||||
android:id="@+id/file_name"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:singleLine="true"/>
|
||||
|
||||
<Button
|
||||
android:id="@+id/fetch_name"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="@string/msg_fetch_filename"
|
||||
android:textColor="?attr/colorPrimary"
|
||||
android:background="?android:selectableItemBackground"/>
|
||||
|
||||
</LinearLayout>
|
||||
|
||||
<LinearLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginLeft="24dp"
|
||||
android:layout_marginRight="24dp"
|
||||
android:layout_marginBottom="24dp"
|
||||
android:gravity="center_vertical"
|
||||
android:orientation="vertical">
|
||||
|
||||
<TextView
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="@string/msg_threads"/>
|
||||
|
||||
<LinearLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:gravity="center_vertical"
|
||||
android:orientation="horizontal">
|
||||
|
||||
<TextView
|
||||
android:id="@+id/threads_count"
|
||||
android:layout_width="20dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="0"/>
|
||||
|
||||
<SeekBar
|
||||
android:id="@+id/threads"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:max="31"
|
||||
android:progress="3"/>
|
||||
|
||||
</LinearLayout>
|
||||
|
||||
</LinearLayout>
|
||||
|
||||
</LinearLayout>
|
||||
81
app/src/main/res/layout/mission_item.xml
Normal file
81
app/src/main/res/layout/mission_item.xml
Normal file
|
|
@ -0,0 +1,81 @@
|
|||
<RelativeLayout
|
||||
xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_width="match_parent">
|
||||
|
||||
<RelativeLayout
|
||||
android:id="@+id/item_bkg"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_margin="2dp"
|
||||
android:background="@color/bluegray">
|
||||
|
||||
<RelativeLayout
|
||||
android:id="@+id/item_title_line"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_alignParentTop="true"
|
||||
android:layout_marginTop="2dp">
|
||||
|
||||
<TextView
|
||||
android:id="@+id/item_status"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_alignParentLeft="true"
|
||||
android:layout_centerVertical="true"
|
||||
android:layout_marginLeft="6dp"
|
||||
android:singleLine="true"
|
||||
android:text="0%"
|
||||
android:textSize="20sp"
|
||||
android:textColor="@color/white"/>
|
||||
|
||||
<ImageView
|
||||
style="?attr/buttonBarButtonStyle"
|
||||
android:id="@+id/item_more"
|
||||
android:layout_width="49dp"
|
||||
android:layout_height="49dp"
|
||||
android:layout_alignParentRight="true"
|
||||
android:layout_centerVertical="true"
|
||||
android:layout_marginRight="1dp"
|
||||
android:src="@drawable/ic_menu_more"
|
||||
android:scaleType="centerInside"/>
|
||||
|
||||
</RelativeLayout>
|
||||
|
||||
<ImageView
|
||||
android:id="@+id/item_icon"
|
||||
android:layout_width="72dp"
|
||||
android:layout_height="72dp"
|
||||
android:layout_below="@id/item_title_line"
|
||||
android:layout_centerHorizontal="true"
|
||||
android:scaleType="fitXY"
|
||||
android:gravity="center"
|
||||
android:padding="10dp"/>
|
||||
|
||||
<TextView
|
||||
android:id="@+id/item_name"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_below="@id/item_icon"
|
||||
android:padding="6dp"
|
||||
android:singleLine="true"
|
||||
android:ellipsize="end"
|
||||
android:text="XXX.xx"
|
||||
android:textSize="16sp"
|
||||
android:textStyle="bold"
|
||||
android:textColor="@color/white"/>
|
||||
|
||||
<TextView
|
||||
android:id="@+id/item_size"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_below="@id/item_name"
|
||||
android:padding="6dp"
|
||||
android:singleLine="true"
|
||||
android:text="100.00MB"
|
||||
android:textSize="12sp"
|
||||
android:textColor="@color/white"/>
|
||||
|
||||
</RelativeLayout>
|
||||
|
||||
</RelativeLayout>
|
||||
83
app/src/main/res/layout/mission_item_linear.xml
Normal file
83
app/src/main/res/layout/mission_item_linear.xml
Normal file
|
|
@ -0,0 +1,83 @@
|
|||
<RelativeLayout
|
||||
xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_width="match_parent">
|
||||
|
||||
<RelativeLayout
|
||||
android:id="@+id/item_bkg"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_margin="2dp"
|
||||
android:background="@color/bluegray">
|
||||
|
||||
<ImageView
|
||||
android:id="@+id/item_icon"
|
||||
android:layout_width="72dp"
|
||||
android:layout_height="72dp"
|
||||
android:layout_centerVertical="true"
|
||||
android:scaleType="fitXY"
|
||||
android:gravity="center"
|
||||
android:padding="15dp"/>
|
||||
|
||||
<LinearLayout
|
||||
android:id="@+id/item_name_and_size"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_toRightOf="@id/item_icon"
|
||||
android:layout_toLeftOf="@+id/item_status"
|
||||
android:layout_centerVertical="true"
|
||||
android:orientation="vertical">
|
||||
|
||||
<TextView
|
||||
android:id="@+id/item_name"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:padding="6dp"
|
||||
android:singleLine="true"
|
||||
android:ellipsize="end"
|
||||
android:text="XXX.xx"
|
||||
android:textSize="16sp"
|
||||
android:textStyle="bold"
|
||||
android:textColor="@color/white"/>
|
||||
|
||||
<TextView
|
||||
android:id="@+id/item_size"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_below="@id/item_name"
|
||||
android:padding="6dp"
|
||||
android:singleLine="true"
|
||||
android:text="100.00MB"
|
||||
android:textSize="12sp"
|
||||
android:textColor="@color/white"/>
|
||||
|
||||
</LinearLayout>
|
||||
|
||||
|
||||
<TextView
|
||||
android:id="@+id/item_status"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_toLeftOf="@+id/item_more"
|
||||
android:layout_centerVertical="true"
|
||||
android:layout_marginLeft="6dp"
|
||||
android:layout_marginRight="6dp"
|
||||
android:singleLine="true"
|
||||
android:text="0%"
|
||||
android:textSize="20sp"
|
||||
android:textColor="@color/white"/>
|
||||
|
||||
<ImageView
|
||||
style="?attr/buttonBarButtonStyle"
|
||||
android:id="@+id/item_more"
|
||||
android:layout_width="36dp"
|
||||
android:layout_height="36dp"
|
||||
android:layout_alignParentRight="true"
|
||||
android:layout_centerVertical="true"
|
||||
android:layout_marginRight="4dp"
|
||||
android:src="@drawable/ic_menu_more"
|
||||
android:scaleType="centerInside"/>
|
||||
|
||||
</RelativeLayout>
|
||||
|
||||
</RelativeLayout>
|
||||
12
app/src/main/res/layout/missions.xml
Normal file
12
app/src/main/res/layout/missions.xml
Normal file
|
|
@ -0,0 +1,12 @@
|
|||
<LinearLayout
|
||||
xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:layout_width="fill_parent"
|
||||
android:layout_height="fill_parent"
|
||||
android:orientation="vertical">
|
||||
|
||||
<android.support.v7.widget.RecyclerView
|
||||
android:id="@+id/mission_recycler"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent"/>
|
||||
|
||||
</LinearLayout>
|
||||
Loading…
Add table
Add a link
Reference in a new issue