Initial release: Claude Pro usage widget for Android
This commit is contained in:
+35
@@ -0,0 +1,35 @@
|
||||
#Fri May 22 14:33:39 UTC 2026
|
||||
me.khodak.claudeusage.app-main-43\:/mipmap-xxxhdpi/ic_launcher.xml=/home/amir/android-projects/claude-usage-widget/app/build/intermediates/merged_res/debug/mipmap-xxxhdpi_ic_launcher.xml.flat
|
||||
me.khodak.claudeusage.app-mergeDebugResources-40\:/layout/activity_login.xml=/home/amir/android-projects/claude-usage-widget/app/build/intermediates/merged_res/debug/layout_activity_login.xml.flat
|
||||
me.khodak.claudeusage.app-main-43\:/mipmap-xxhdpi/ic_launcher.xml=/home/amir/android-projects/claude-usage-widget/app/build/intermediates/merged_res/debug/mipmap-xxhdpi_ic_launcher.xml.flat
|
||||
me.khodak.claudeusage.app-main-43\:/drawable/ic_launcher_fg.xml=/home/amir/android-projects/claude-usage-widget/app/build/intermediates/merged_res/debug/drawable_ic_launcher_fg.xml.flat
|
||||
me.khodak.claudeusage.app-main-43\:/mipmap-mdpi/ic_launcher_round.xml=/home/amir/android-projects/claude-usage-widget/app/build/intermediates/merged_res/debug/mipmap-mdpi_ic_launcher_round.xml.flat
|
||||
me.khodak.claudeusage.app-main-42\:/mipmap-xxhdpi/ic_launcher_round.xml=/home/amir/android-projects/claude-usage-widget/app/build/intermediates/merged_res/debug/mipmap-xxhdpi_ic_launcher_round.xml.flat
|
||||
me.khodak.claudeusage.app-mergeDebugResources-40\:/layout/widget_layout.xml=/home/amir/android-projects/claude-usage-widget/app/build/intermediates/merged_res/debug/layout_widget_layout.xml.flat
|
||||
me.khodak.claudeusage.app-main-42\:/mipmap-xhdpi/ic_launcher_round.xml=/home/amir/android-projects/claude-usage-widget/app/build/intermediates/merged_res/debug/mipmap-xhdpi_ic_launcher_round.xml.flat
|
||||
me.khodak.claudeusage.app-main-42\:/mipmap-hdpi/ic_launcher_round.xml=/home/amir/android-projects/claude-usage-widget/app/build/intermediates/merged_res/debug/mipmap-hdpi_ic_launcher_round.xml.flat
|
||||
me.khodak.claudeusage.app-main-42\:/mipmap-hdpi/ic_launcher.xml=/home/amir/android-projects/claude-usage-widget/app/build/intermediates/merged_res/debug/mipmap-hdpi_ic_launcher.xml.flat
|
||||
me.khodak.claudeusage.app-main-43\:/mipmap-mdpi/ic_launcher.xml=/home/amir/android-projects/claude-usage-widget/app/build/intermediates/merged_res/debug/mipmap-mdpi_ic_launcher.xml.flat
|
||||
me.khodak.claudeusage.app-main-42\:/mipmap-xxxhdpi/ic_launcher_round.xml=/home/amir/android-projects/claude-usage-widget/app/build/intermediates/merged_res/debug/mipmap-xxxhdpi_ic_launcher_round.xml.flat
|
||||
me.khodak.claudeusage.app-main-43\:/mipmap-xxxhdpi/ic_launcher_round.xml=/home/amir/android-projects/claude-usage-widget/app/build/intermediates/merged_res/debug/mipmap-xxxhdpi_ic_launcher_round.xml.flat
|
||||
me.khodak.claudeusage.app-mergeDebugResources-39\:/layout/activity_login.xml=/home/amir/android-projects/claude-usage-widget/app/build/intermediates/merged_res/debug/layout_activity_login.xml.flat
|
||||
me.khodak.claudeusage.app-main-42\:/mipmap-xxxhdpi/ic_launcher.xml=/home/amir/android-projects/claude-usage-widget/app/build/intermediates/merged_res/debug/mipmap-xxxhdpi_ic_launcher.xml.flat
|
||||
me.khodak.claudeusage.app-mergeDebugResources-39\:/layout/widget_layout.xml=/home/amir/android-projects/claude-usage-widget/app/build/intermediates/merged_res/debug/layout_widget_layout.xml.flat
|
||||
me.khodak.claudeusage.app-main-43\:/drawable/widget_background.xml=/home/amir/android-projects/claude-usage-widget/app/build/intermediates/merged_res/debug/drawable_widget_background.xml.flat
|
||||
me.khodak.claudeusage.app-main-42\:/mipmap-mdpi/ic_launcher.xml=/home/amir/android-projects/claude-usage-widget/app/build/intermediates/merged_res/debug/mipmap-mdpi_ic_launcher.xml.flat
|
||||
me.khodak.claudeusage.app-main-43\:/xml/widget_info.xml=/home/amir/android-projects/claude-usage-widget/app/build/intermediates/merged_res/debug/xml_widget_info.xml.flat
|
||||
me.khodak.claudeusage.app-main-43\:/mipmap-xxhdpi/ic_launcher_round.xml=/home/amir/android-projects/claude-usage-widget/app/build/intermediates/merged_res/debug/mipmap-xxhdpi_ic_launcher_round.xml.flat
|
||||
me.khodak.claudeusage.app-main-42\:/mipmap-xhdpi/ic_launcher.xml=/home/amir/android-projects/claude-usage-widget/app/build/intermediates/merged_res/debug/mipmap-xhdpi_ic_launcher.xml.flat
|
||||
me.khodak.claudeusage.app-mergeDebugResources-40\:/layout/widget_layout_small.xml=/home/amir/android-projects/claude-usage-widget/app/build/intermediates/merged_res/debug/layout_widget_layout_small.xml.flat
|
||||
me.khodak.claudeusage.app-main-42\:/drawable/widget_background.xml=/home/amir/android-projects/claude-usage-widget/app/build/intermediates/merged_res/debug/drawable_widget_background.xml.flat
|
||||
me.khodak.claudeusage.app-main-43\:/mipmap-hdpi/ic_launcher.xml=/home/amir/android-projects/claude-usage-widget/app/build/intermediates/merged_res/debug/mipmap-hdpi_ic_launcher.xml.flat
|
||||
me.khodak.claudeusage.app-main-43\:/mipmap-xhdpi/ic_launcher_round.xml=/home/amir/android-projects/claude-usage-widget/app/build/intermediates/merged_res/debug/mipmap-xhdpi_ic_launcher_round.xml.flat
|
||||
me.khodak.claudeusage.app-mergeDebugResources-40\:/layout/activity_main.xml=/home/amir/android-projects/claude-usage-widget/app/build/intermediates/merged_res/debug/layout_activity_main.xml.flat
|
||||
me.khodak.claudeusage.app-main-42\:/mipmap-mdpi/ic_launcher_round.xml=/home/amir/android-projects/claude-usage-widget/app/build/intermediates/merged_res/debug/mipmap-mdpi_ic_launcher_round.xml.flat
|
||||
me.khodak.claudeusage.app-main-43\:/mipmap-hdpi/ic_launcher_round.xml=/home/amir/android-projects/claude-usage-widget/app/build/intermediates/merged_res/debug/mipmap-hdpi_ic_launcher_round.xml.flat
|
||||
me.khodak.claudeusage.app-main-42\:/xml/widget_info.xml=/home/amir/android-projects/claude-usage-widget/app/build/intermediates/merged_res/debug/xml_widget_info.xml.flat
|
||||
me.khodak.claudeusage.app-main-42\:/mipmap-xxhdpi/ic_launcher.xml=/home/amir/android-projects/claude-usage-widget/app/build/intermediates/merged_res/debug/mipmap-xxhdpi_ic_launcher.xml.flat
|
||||
me.khodak.claudeusage.app-main-43\:/drawable/badge_background.xml=/home/amir/android-projects/claude-usage-widget/app/build/intermediates/merged_res/debug/drawable_badge_background.xml.flat
|
||||
me.khodak.claudeusage.app-mergeDebugResources-39\:/layout/activity_main.xml=/home/amir/android-projects/claude-usage-widget/app/build/intermediates/merged_res/debug/layout_activity_main.xml.flat
|
||||
me.khodak.claudeusage.app-main-42\:/drawable/ic_launcher_fg.xml=/home/amir/android-projects/claude-usage-widget/app/build/intermediates/merged_res/debug/drawable_ic_launcher_fg.xml.flat
|
||||
me.khodak.claudeusage.app-main-43\:/mipmap-xhdpi/ic_launcher.xml=/home/amir/android-projects/claude-usage-widget/app/build/intermediates/merged_res/debug/mipmap-xhdpi_ic_launcher.xml.flat
|
||||
File diff suppressed because one or more lines are too long
+244
@@ -0,0 +1,244 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<ScrollView xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent"
|
||||
android:fillViewport="true"
|
||||
android:background="#121212">
|
||||
|
||||
<LinearLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:orientation="vertical"
|
||||
android:padding="24dp"
|
||||
android:gravity="center_horizontal">
|
||||
|
||||
<!-- Logo / Title -->
|
||||
<TextView
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginTop="32dp"
|
||||
android:text="⬡"
|
||||
android:textColor="#CC785C"
|
||||
android:textSize="48sp" />
|
||||
|
||||
<TextView
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginTop="8dp"
|
||||
android:text="Claude Usage"
|
||||
android:textColor="#FFFFFF"
|
||||
android:textSize="24sp"
|
||||
android:textStyle="bold" />
|
||||
|
||||
<TextView
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginTop="4dp"
|
||||
android:text="Home screen widget"
|
||||
android:textColor="#888888"
|
||||
android:textSize="14sp" />
|
||||
|
||||
<!-- Loading indicator -->
|
||||
<ProgressBar
|
||||
android:id="@+id/progressIndicator"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginTop="16dp"
|
||||
android:visibility="gone" />
|
||||
|
||||
<!-- LOGGED OUT state -->
|
||||
<LinearLayout
|
||||
android:id="@+id/layoutLoggedOut"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:orientation="vertical"
|
||||
android:layout_marginTop="48dp"
|
||||
android:gravity="center">
|
||||
|
||||
<TextView
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="Sign in with your Claude account to track Pro usage on your home screen widget."
|
||||
android:textColor="#AAAAAA"
|
||||
android:textSize="14sp"
|
||||
android:textAlignment="center"
|
||||
android:lineSpacingExtra="4dp" />
|
||||
|
||||
<Button
|
||||
android:id="@+id/btnLogin"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginTop="24dp"
|
||||
android:text="Sign in to Claude"
|
||||
android:backgroundTint="#CC785C"
|
||||
android:textColor="#FFFFFF" />
|
||||
|
||||
</LinearLayout>
|
||||
|
||||
<!-- LOGGED IN state -->
|
||||
<LinearLayout
|
||||
android:id="@+id/layoutLoggedIn"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:orientation="vertical"
|
||||
android:layout_marginTop="32dp"
|
||||
android:visibility="gone">
|
||||
|
||||
<!-- Usage card -->
|
||||
<LinearLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:orientation="vertical"
|
||||
android:background="@drawable/widget_background"
|
||||
android:padding="20dp">
|
||||
|
||||
<TextView
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="CURRENT USAGE"
|
||||
android:textColor="#888888"
|
||||
android:textSize="11sp"
|
||||
android:letterSpacing="0.1" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/tvUsage"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginTop="8dp"
|
||||
android:text="—"
|
||||
android:textColor="#FFFFFF"
|
||||
android:textSize="20sp"
|
||||
android:textStyle="bold" />
|
||||
|
||||
<ProgressBar
|
||||
android:id="@+id/progressBar"
|
||||
style="@android:style/Widget.ProgressBar.Horizontal"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="8dp"
|
||||
android:layout_marginTop="12dp"
|
||||
android:max="100"
|
||||
android:progress="0"
|
||||
android:progressTint="#CC785C"
|
||||
android:progressBackgroundTint="#3A3A3A" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/tvReset"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginTop="4dp"
|
||||
android:textColor="#888888"
|
||||
android:textSize="13sp" />
|
||||
|
||||
<TextView
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginTop="16dp"
|
||||
android:text="WEEKLY"
|
||||
android:textColor="#888888"
|
||||
android:textSize="11sp"
|
||||
android:letterSpacing="0.1" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/tvWeeklyUsage"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginTop="4dp"
|
||||
android:text="—"
|
||||
android:textColor="#FFFFFF"
|
||||
android:textSize="16sp"
|
||||
android:textStyle="bold" />
|
||||
|
||||
<ProgressBar
|
||||
android:id="@+id/progressBarWeekly"
|
||||
style="@android:style/Widget.ProgressBar.Horizontal"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="8dp"
|
||||
android:layout_marginTop="8dp"
|
||||
android:max="100"
|
||||
android:progress="0"
|
||||
android:progressTint="#7B8FCC"
|
||||
android:progressBackgroundTint="#3A3A3A" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/tvWeeklyReset"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginTop="4dp"
|
||||
android:textColor="#888888"
|
||||
android:textSize="13sp" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/tvUpdated"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginTop="4dp"
|
||||
android:textColor="#666666"
|
||||
android:textSize="12sp" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/tvError"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginTop="8dp"
|
||||
android:textColor="#FF7070"
|
||||
android:textSize="12sp"
|
||||
android:visibility="gone" />
|
||||
|
||||
</LinearLayout>
|
||||
|
||||
<Button
|
||||
android:id="@+id/btnRefresh"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginTop="16dp"
|
||||
android:text="Refresh Now"
|
||||
android:backgroundTint="#CC785C"
|
||||
android:textColor="#FFFFFF" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/tvWidgetHint"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginTop="24dp"
|
||||
android:text="Long-press your home screen → Widgets → Claude Usage to add the widget"
|
||||
android:textColor="#666666"
|
||||
android:textSize="13sp"
|
||||
android:textAlignment="center"
|
||||
android:lineSpacingExtra="4dp"
|
||||
android:padding="8dp" />
|
||||
|
||||
<Button
|
||||
android:id="@+id/btnLogout"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginTop="8dp"
|
||||
android:text="Sign Out"
|
||||
android:backgroundTint="#2A2A2A"
|
||||
android:textColor="#888888" />
|
||||
|
||||
<Button
|
||||
android:id="@+id/btnDebug"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginTop="4dp"
|
||||
android:text="Show API Debug"
|
||||
android:backgroundTint="#1A1A1A"
|
||||
android:textColor="#555555"
|
||||
android:textSize="12sp" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/tvDebugInfo"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginTop="8dp"
|
||||
android:padding="12dp"
|
||||
android:background="#1A1A1A"
|
||||
android:textColor="#888888"
|
||||
android:textSize="11sp"
|
||||
android:fontFamily="monospace"
|
||||
android:visibility="gone" />
|
||||
|
||||
</LinearLayout>
|
||||
|
||||
</LinearLayout>
|
||||
</ScrollView>
|
||||
+169
@@ -0,0 +1,169 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:id="@+id/widget_root"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent"
|
||||
android:orientation="vertical"
|
||||
android:background="@drawable/widget_background"
|
||||
android:padding="14dp">
|
||||
|
||||
<!-- Header -->
|
||||
<LinearLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:orientation="horizontal"
|
||||
android:gravity="center_vertical">
|
||||
|
||||
<TextView
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="1"
|
||||
android:text="Claude Pro"
|
||||
android:textColor="#FFFFFF"
|
||||
android:textSize="13sp"
|
||||
android:textStyle="bold" />
|
||||
|
||||
<ImageButton
|
||||
android:id="@+id/btn_refresh"
|
||||
android:layout_width="24dp"
|
||||
android:layout_height="24dp"
|
||||
android:src="@android:drawable/ic_menu_rotate"
|
||||
android:background="@android:color/transparent"
|
||||
android:tint="#999999"
|
||||
android:contentDescription="Refresh" />
|
||||
|
||||
</LinearLayout>
|
||||
|
||||
<!-- Divider — View is not in RemoteViews allowlist on Android 12+; use TextView instead -->
|
||||
<TextView
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="1dp"
|
||||
android:layout_marginTop="8dp"
|
||||
android:layout_marginBottom="10dp"
|
||||
android:background="#2A2A2A" />
|
||||
|
||||
<!-- 5-hour window bar -->
|
||||
<LinearLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:orientation="horizontal"
|
||||
android:gravity="center_vertical">
|
||||
|
||||
<TextView
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="1"
|
||||
android:text="SESSION"
|
||||
android:textColor="#555555"
|
||||
android:textSize="9sp"
|
||||
android:textStyle="bold" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/tv_session_value"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="—"
|
||||
android:textColor="#FFFFFF"
|
||||
android:textSize="13sp"
|
||||
android:textStyle="bold" />
|
||||
|
||||
</LinearLayout>
|
||||
|
||||
<ProgressBar
|
||||
android:id="@+id/progress_bar"
|
||||
style="@android:style/Widget.ProgressBar.Horizontal"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="5dp"
|
||||
android:layout_marginTop="5dp"
|
||||
android:max="100"
|
||||
android:progress="0"
|
||||
android:progressTint="#CC785C"
|
||||
android:progressBackgroundTint="#252525" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/tv_session_label"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginTop="3dp"
|
||||
android:text=""
|
||||
android:textColor="#666666"
|
||||
android:textSize="9sp" />
|
||||
|
||||
<!-- 7-day window bar -->
|
||||
<LinearLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:orientation="horizontal"
|
||||
android:gravity="center_vertical"
|
||||
android:layout_marginTop="10dp">
|
||||
|
||||
<TextView
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="1"
|
||||
android:text="WEEKLY"
|
||||
android:textColor="#555555"
|
||||
android:textSize="9sp"
|
||||
android:textStyle="bold" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/tv_weekly_value"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="—"
|
||||
android:textColor="#FFFFFF"
|
||||
android:textSize="13sp"
|
||||
android:textStyle="bold" />
|
||||
|
||||
</LinearLayout>
|
||||
|
||||
<ProgressBar
|
||||
android:id="@+id/progress_bar_weekly"
|
||||
style="@android:style/Widget.ProgressBar.Horizontal"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="5dp"
|
||||
android:layout_marginTop="5dp"
|
||||
android:max="100"
|
||||
android:progress="0"
|
||||
android:progressTint="#7B8FCC"
|
||||
android:progressBackgroundTint="#252525" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/tv_weekly_label"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginTop="3dp"
|
||||
android:text=""
|
||||
android:textColor="#666666"
|
||||
android:textSize="9sp" />
|
||||
|
||||
<!-- Footer -->
|
||||
<LinearLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:orientation="horizontal"
|
||||
android:layout_marginTop="8dp"
|
||||
android:gravity="center_vertical">
|
||||
|
||||
<TextView
|
||||
android:id="@+id/tv_status"
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="1"
|
||||
android:text=""
|
||||
android:textColor="#CC785C"
|
||||
android:textSize="9sp"
|
||||
android:singleLine="true"
|
||||
android:ellipsize="end" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/tv_updated"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:text=""
|
||||
android:textColor="#444444"
|
||||
android:textSize="9sp" />
|
||||
|
||||
</LinearLayout>
|
||||
|
||||
</LinearLayout>
|
||||
+19
@@ -0,0 +1,19 @@
|
||||
#Fri May 22 14:33:40 UTC 2026
|
||||
me.khodak.claudeusage.app-main-5\:/mipmap-xxhdpi/ic_launcher_round.xml=/home/amir/android-projects/claude-usage-widget/app/build/intermediates/packaged_res/debug/mipmap-xxhdpi-v4/ic_launcher_round.xml
|
||||
me.khodak.claudeusage.app-main-5\:/mipmap-hdpi/ic_launcher.xml=/home/amir/android-projects/claude-usage-widget/app/build/intermediates/packaged_res/debug/mipmap-hdpi-v4/ic_launcher.xml
|
||||
me.khodak.claudeusage.app-main-5\:/mipmap-xhdpi/ic_launcher.xml=/home/amir/android-projects/claude-usage-widget/app/build/intermediates/packaged_res/debug/mipmap-xhdpi-v4/ic_launcher.xml
|
||||
me.khodak.claudeusage.app-packageDebugResources-2\:/layout/activity_login.xml=/home/amir/android-projects/claude-usage-widget/app/build/intermediates/packaged_res/debug/layout/activity_login.xml
|
||||
me.khodak.claudeusage.app-main-5\:/mipmap-xxxhdpi/ic_launcher_round.xml=/home/amir/android-projects/claude-usage-widget/app/build/intermediates/packaged_res/debug/mipmap-xxxhdpi-v4/ic_launcher_round.xml
|
||||
me.khodak.claudeusage.app-packageDebugResources-2\:/layout/widget_layout.xml=/home/amir/android-projects/claude-usage-widget/app/build/intermediates/packaged_res/debug/layout/widget_layout.xml
|
||||
me.khodak.claudeusage.app-main-5\:/xml/widget_info.xml=/home/amir/android-projects/claude-usage-widget/app/build/intermediates/packaged_res/debug/xml/widget_info.xml
|
||||
me.khodak.claudeusage.app-packageDebugResources-2\:/layout/activity_main.xml=/home/amir/android-projects/claude-usage-widget/app/build/intermediates/packaged_res/debug/layout/activity_main.xml
|
||||
me.khodak.claudeusage.app-main-5\:/mipmap-mdpi/ic_launcher_round.xml=/home/amir/android-projects/claude-usage-widget/app/build/intermediates/packaged_res/debug/mipmap-mdpi-v4/ic_launcher_round.xml
|
||||
me.khodak.claudeusage.app-packageDebugResources-2\:/layout/widget_layout_small.xml=/home/amir/android-projects/claude-usage-widget/app/build/intermediates/packaged_res/debug/layout/widget_layout_small.xml
|
||||
me.khodak.claudeusage.app-main-5\:/mipmap-hdpi/ic_launcher_round.xml=/home/amir/android-projects/claude-usage-widget/app/build/intermediates/packaged_res/debug/mipmap-hdpi-v4/ic_launcher_round.xml
|
||||
me.khodak.claudeusage.app-main-5\:/mipmap-mdpi/ic_launcher.xml=/home/amir/android-projects/claude-usage-widget/app/build/intermediates/packaged_res/debug/mipmap-mdpi-v4/ic_launcher.xml
|
||||
me.khodak.claudeusage.app-main-5\:/drawable/ic_launcher_fg.xml=/home/amir/android-projects/claude-usage-widget/app/build/intermediates/packaged_res/debug/drawable/ic_launcher_fg.xml
|
||||
me.khodak.claudeusage.app-main-5\:/mipmap-xxxhdpi/ic_launcher.xml=/home/amir/android-projects/claude-usage-widget/app/build/intermediates/packaged_res/debug/mipmap-xxxhdpi-v4/ic_launcher.xml
|
||||
me.khodak.claudeusage.app-main-5\:/mipmap-xxhdpi/ic_launcher.xml=/home/amir/android-projects/claude-usage-widget/app/build/intermediates/packaged_res/debug/mipmap-xxhdpi-v4/ic_launcher.xml
|
||||
me.khodak.claudeusage.app-main-5\:/drawable/badge_background.xml=/home/amir/android-projects/claude-usage-widget/app/build/intermediates/packaged_res/debug/drawable/badge_background.xml
|
||||
me.khodak.claudeusage.app-main-5\:/drawable/widget_background.xml=/home/amir/android-projects/claude-usage-widget/app/build/intermediates/packaged_res/debug/drawable/widget_background.xml
|
||||
me.khodak.claudeusage.app-main-5\:/mipmap-xhdpi/ic_launcher_round.xml=/home/amir/android-projects/claude-usage-widget/app/build/intermediates/packaged_res/debug/mipmap-xhdpi-v4/ic_launcher_round.xml
|
||||
@@ -0,0 +1,9 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<merger version="3"><dataSet aapt-namespace="http://schemas.android.com/apk/res-auto" config="main$Generated" generated="true" ignore_pattern="!.svn:!.git:!.ds_store:!*.scc:.*:<dir>_*:!CVS:!thumbs.db:!picasa.ini:!*~"><source path="/home/amir/android-projects/claude-usage-widget/app/src/main/res"/></dataSet><dataSet aapt-namespace="http://schemas.android.com/apk/res-auto" config="main" generated-set="main$Generated" ignore_pattern="!.svn:!.git:!.ds_store:!*.scc:.*:<dir>_*:!CVS:!thumbs.db:!picasa.ini:!*~"><source path="/home/amir/android-projects/claude-usage-widget/app/src/main/res"><file name="ic_launcher_round" path="/home/amir/android-projects/claude-usage-widget/app/src/main/res/mipmap-hdpi/ic_launcher_round.xml" qualifiers="hdpi-v4" type="mipmap"/><file name="ic_launcher" path="/home/amir/android-projects/claude-usage-widget/app/src/main/res/mipmap-hdpi/ic_launcher.xml" qualifiers="hdpi-v4" type="mipmap"/><file name="widget_info" path="/home/amir/android-projects/claude-usage-widget/app/src/main/res/xml/widget_info.xml" qualifiers="" type="xml"/><file name="ic_launcher_round" path="/home/amir/android-projects/claude-usage-widget/app/src/main/res/mipmap-xhdpi/ic_launcher_round.xml" qualifiers="xhdpi-v4" type="mipmap"/><file name="ic_launcher" path="/home/amir/android-projects/claude-usage-widget/app/src/main/res/mipmap-xhdpi/ic_launcher.xml" qualifiers="xhdpi-v4" type="mipmap"/><file name="ic_launcher_round" path="/home/amir/android-projects/claude-usage-widget/app/src/main/res/mipmap-xxhdpi/ic_launcher_round.xml" qualifiers="xxhdpi-v4" type="mipmap"/><file name="ic_launcher" path="/home/amir/android-projects/claude-usage-widget/app/src/main/res/mipmap-xxhdpi/ic_launcher.xml" qualifiers="xxhdpi-v4" type="mipmap"/><file name="widget_layout" path="/home/amir/android-projects/claude-usage-widget/app/src/main/res/layout/widget_layout.xml" qualifiers="" type="layout"/><file name="activity_login" path="/home/amir/android-projects/claude-usage-widget/app/src/main/res/layout/activity_login.xml" qualifiers="" type="layout"/><file name="activity_main" path="/home/amir/android-projects/claude-usage-widget/app/src/main/res/layout/activity_main.xml" qualifiers="" type="layout"/><file name="ic_launcher_round" path="/home/amir/android-projects/claude-usage-widget/app/src/main/res/mipmap-mdpi/ic_launcher_round.xml" qualifiers="mdpi-v4" type="mipmap"/><file name="ic_launcher" path="/home/amir/android-projects/claude-usage-widget/app/src/main/res/mipmap-mdpi/ic_launcher.xml" qualifiers="mdpi-v4" type="mipmap"/><file name="ic_launcher_round" path="/home/amir/android-projects/claude-usage-widget/app/src/main/res/mipmap-xxxhdpi/ic_launcher_round.xml" qualifiers="xxxhdpi-v4" type="mipmap"/><file name="ic_launcher" path="/home/amir/android-projects/claude-usage-widget/app/src/main/res/mipmap-xxxhdpi/ic_launcher.xml" qualifiers="xxxhdpi-v4" type="mipmap"/><file name="widget_background" path="/home/amir/android-projects/claude-usage-widget/app/src/main/res/drawable/widget_background.xml" qualifiers="" type="drawable"/><file name="ic_launcher_fg" path="/home/amir/android-projects/claude-usage-widget/app/src/main/res/drawable/ic_launcher_fg.xml" qualifiers="" type="drawable"/><file path="/home/amir/android-projects/claude-usage-widget/app/src/main/res/values/strings.xml" qualifiers=""><string name="app_name">Claude Usage</string><string name="login_title">Sign in to Claude</string><string name="widget_description">Shows your Claude Pro message usage</string></file><file path="/home/amir/android-projects/claude-usage-widget/app/src/main/res/values/themes.xml" qualifiers=""><style name="Theme.ClaudeUsage" parent="Theme.MaterialComponents.DayNight.NoActionBar">
|
||||
<item name="colorPrimary">@color/claude_orange</item>
|
||||
<item name="colorPrimaryVariant">@color/claude_orange</item>
|
||||
<item name="colorOnPrimary">@color/text_primary</item>
|
||||
<item name="android:windowBackground">@color/background_dark</item>
|
||||
<item name="android:statusBarColor">@color/background_dark</item>
|
||||
<item name="android:navigationBarColor">@color/background_dark</item>
|
||||
</style></file><file path="/home/amir/android-projects/claude-usage-widget/app/src/main/res/values/colors.xml" qualifiers=""><color name="claude_orange">#CC785C</color><color name="background_dark">#121212</color><color name="surface_dark">#1E1E1E</color><color name="text_primary">#FFFFFF</color><color name="text_secondary">#888888</color></file><file name="badge_background" path="/home/amir/android-projects/claude-usage-widget/app/src/main/res/drawable/badge_background.xml" qualifiers="" type="drawable"/><file name="widget_layout_small" path="/home/amir/android-projects/claude-usage-widget/app/src/main/res/layout/widget_layout_small.xml" qualifiers="" type="layout"/></source></dataSet><dataSet aapt-namespace="http://schemas.android.com/apk/res-auto" config="debug$Generated" generated="true" ignore_pattern="!.svn:!.git:!.ds_store:!*.scc:.*:<dir>_*:!CVS:!thumbs.db:!picasa.ini:!*~"><source path="/home/amir/android-projects/claude-usage-widget/app/src/debug/res"/></dataSet><dataSet aapt-namespace="http://schemas.android.com/apk/res-auto" config="debug" generated-set="debug$Generated" ignore_pattern="!.svn:!.git:!.ds_store:!*.scc:.*:<dir>_*:!CVS:!thumbs.db:!picasa.ini:!*~"><source path="/home/amir/android-projects/claude-usage-widget/app/src/debug/res"/></dataSet><dataSet aapt-namespace="http://schemas.android.com/apk/res-auto" config="generated$Generated" generated="true" ignore_pattern="!.svn:!.git:!.ds_store:!*.scc:.*:<dir>_*:!CVS:!thumbs.db:!picasa.ini:!*~"><source path="/home/amir/android-projects/claude-usage-widget/app/build/generated/res/resValues/debug"/></dataSet><dataSet aapt-namespace="http://schemas.android.com/apk/res-auto" config="generated" generated-set="generated$Generated" ignore_pattern="!.svn:!.git:!.ds_store:!*.scc:.*:<dir>_*:!CVS:!thumbs.db:!picasa.ini:!*~"><source path="/home/amir/android-projects/claude-usage-widget/app/build/generated/res/resValues/debug"/></dataSet><mergedItems/></merger>
|
||||
+244
@@ -0,0 +1,244 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<ScrollView xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent"
|
||||
android:fillViewport="true"
|
||||
android:background="#121212">
|
||||
|
||||
<LinearLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:orientation="vertical"
|
||||
android:padding="24dp"
|
||||
android:gravity="center_horizontal">
|
||||
|
||||
<!-- Logo / Title -->
|
||||
<TextView
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginTop="32dp"
|
||||
android:text="⬡"
|
||||
android:textColor="#CC785C"
|
||||
android:textSize="48sp" />
|
||||
|
||||
<TextView
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginTop="8dp"
|
||||
android:text="Claude Usage"
|
||||
android:textColor="#FFFFFF"
|
||||
android:textSize="24sp"
|
||||
android:textStyle="bold" />
|
||||
|
||||
<TextView
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginTop="4dp"
|
||||
android:text="Home screen widget"
|
||||
android:textColor="#888888"
|
||||
android:textSize="14sp" />
|
||||
|
||||
<!-- Loading indicator -->
|
||||
<ProgressBar
|
||||
android:id="@+id/progressIndicator"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginTop="16dp"
|
||||
android:visibility="gone" />
|
||||
|
||||
<!-- LOGGED OUT state -->
|
||||
<LinearLayout
|
||||
android:id="@+id/layoutLoggedOut"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:orientation="vertical"
|
||||
android:layout_marginTop="48dp"
|
||||
android:gravity="center">
|
||||
|
||||
<TextView
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="Sign in with your Claude account to track Pro usage on your home screen widget."
|
||||
android:textColor="#AAAAAA"
|
||||
android:textSize="14sp"
|
||||
android:textAlignment="center"
|
||||
android:lineSpacingExtra="4dp" />
|
||||
|
||||
<Button
|
||||
android:id="@+id/btnLogin"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginTop="24dp"
|
||||
android:text="Sign in to Claude"
|
||||
android:backgroundTint="#CC785C"
|
||||
android:textColor="#FFFFFF" />
|
||||
|
||||
</LinearLayout>
|
||||
|
||||
<!-- LOGGED IN state -->
|
||||
<LinearLayout
|
||||
android:id="@+id/layoutLoggedIn"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:orientation="vertical"
|
||||
android:layout_marginTop="32dp"
|
||||
android:visibility="gone">
|
||||
|
||||
<!-- Usage card -->
|
||||
<LinearLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:orientation="vertical"
|
||||
android:background="@drawable/widget_background"
|
||||
android:padding="20dp">
|
||||
|
||||
<TextView
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="CURRENT USAGE"
|
||||
android:textColor="#888888"
|
||||
android:textSize="11sp"
|
||||
android:letterSpacing="0.1" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/tvUsage"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginTop="8dp"
|
||||
android:text="—"
|
||||
android:textColor="#FFFFFF"
|
||||
android:textSize="20sp"
|
||||
android:textStyle="bold" />
|
||||
|
||||
<ProgressBar
|
||||
android:id="@+id/progressBar"
|
||||
style="@android:style/Widget.ProgressBar.Horizontal"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="8dp"
|
||||
android:layout_marginTop="12dp"
|
||||
android:max="100"
|
||||
android:progress="0"
|
||||
android:progressTint="#CC785C"
|
||||
android:progressBackgroundTint="#3A3A3A" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/tvReset"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginTop="4dp"
|
||||
android:textColor="#888888"
|
||||
android:textSize="13sp" />
|
||||
|
||||
<TextView
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginTop="16dp"
|
||||
android:text="WEEKLY"
|
||||
android:textColor="#888888"
|
||||
android:textSize="11sp"
|
||||
android:letterSpacing="0.1" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/tvWeeklyUsage"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginTop="4dp"
|
||||
android:text="—"
|
||||
android:textColor="#FFFFFF"
|
||||
android:textSize="16sp"
|
||||
android:textStyle="bold" />
|
||||
|
||||
<ProgressBar
|
||||
android:id="@+id/progressBarWeekly"
|
||||
style="@android:style/Widget.ProgressBar.Horizontal"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="8dp"
|
||||
android:layout_marginTop="8dp"
|
||||
android:max="100"
|
||||
android:progress="0"
|
||||
android:progressTint="#7B8FCC"
|
||||
android:progressBackgroundTint="#3A3A3A" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/tvWeeklyReset"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginTop="4dp"
|
||||
android:textColor="#888888"
|
||||
android:textSize="13sp" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/tvUpdated"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginTop="4dp"
|
||||
android:textColor="#666666"
|
||||
android:textSize="12sp" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/tvError"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginTop="8dp"
|
||||
android:textColor="#FF7070"
|
||||
android:textSize="12sp"
|
||||
android:visibility="gone" />
|
||||
|
||||
</LinearLayout>
|
||||
|
||||
<Button
|
||||
android:id="@+id/btnRefresh"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginTop="16dp"
|
||||
android:text="Refresh Now"
|
||||
android:backgroundTint="#CC785C"
|
||||
android:textColor="#FFFFFF" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/tvWidgetHint"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginTop="24dp"
|
||||
android:text="Long-press your home screen → Widgets → Claude Usage to add the widget"
|
||||
android:textColor="#666666"
|
||||
android:textSize="13sp"
|
||||
android:textAlignment="center"
|
||||
android:lineSpacingExtra="4dp"
|
||||
android:padding="8dp" />
|
||||
|
||||
<Button
|
||||
android:id="@+id/btnLogout"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginTop="8dp"
|
||||
android:text="Sign Out"
|
||||
android:backgroundTint="#2A2A2A"
|
||||
android:textColor="#888888" />
|
||||
|
||||
<Button
|
||||
android:id="@+id/btnDebug"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginTop="4dp"
|
||||
android:text="Show API Debug"
|
||||
android:backgroundTint="#1A1A1A"
|
||||
android:textColor="#555555"
|
||||
android:textSize="12sp" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/tvDebugInfo"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginTop="8dp"
|
||||
android:padding="12dp"
|
||||
android:background="#1A1A1A"
|
||||
android:textColor="#888888"
|
||||
android:textSize="11sp"
|
||||
android:fontFamily="monospace"
|
||||
android:visibility="gone" />
|
||||
|
||||
</LinearLayout>
|
||||
|
||||
</LinearLayout>
|
||||
</ScrollView>
|
||||
+169
@@ -0,0 +1,169 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:id="@+id/widget_root"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent"
|
||||
android:orientation="vertical"
|
||||
android:background="@drawable/widget_background"
|
||||
android:padding="14dp">
|
||||
|
||||
<!-- Header -->
|
||||
<LinearLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:orientation="horizontal"
|
||||
android:gravity="center_vertical">
|
||||
|
||||
<TextView
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="1"
|
||||
android:text="Claude Pro"
|
||||
android:textColor="#FFFFFF"
|
||||
android:textSize="13sp"
|
||||
android:textStyle="bold" />
|
||||
|
||||
<ImageButton
|
||||
android:id="@+id/btn_refresh"
|
||||
android:layout_width="24dp"
|
||||
android:layout_height="24dp"
|
||||
android:src="@android:drawable/ic_menu_rotate"
|
||||
android:background="@android:color/transparent"
|
||||
android:tint="#999999"
|
||||
android:contentDescription="Refresh" />
|
||||
|
||||
</LinearLayout>
|
||||
|
||||
<!-- Divider — View is not in RemoteViews allowlist on Android 12+; use TextView instead -->
|
||||
<TextView
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="1dp"
|
||||
android:layout_marginTop="8dp"
|
||||
android:layout_marginBottom="10dp"
|
||||
android:background="#2A2A2A" />
|
||||
|
||||
<!-- 5-hour window bar -->
|
||||
<LinearLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:orientation="horizontal"
|
||||
android:gravity="center_vertical">
|
||||
|
||||
<TextView
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="1"
|
||||
android:text="SESSION"
|
||||
android:textColor="#555555"
|
||||
android:textSize="9sp"
|
||||
android:textStyle="bold" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/tv_session_value"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="—"
|
||||
android:textColor="#FFFFFF"
|
||||
android:textSize="13sp"
|
||||
android:textStyle="bold" />
|
||||
|
||||
</LinearLayout>
|
||||
|
||||
<ProgressBar
|
||||
android:id="@+id/progress_bar"
|
||||
style="@android:style/Widget.ProgressBar.Horizontal"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="5dp"
|
||||
android:layout_marginTop="5dp"
|
||||
android:max="100"
|
||||
android:progress="0"
|
||||
android:progressTint="#CC785C"
|
||||
android:progressBackgroundTint="#252525" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/tv_session_label"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginTop="3dp"
|
||||
android:text=""
|
||||
android:textColor="#666666"
|
||||
android:textSize="9sp" />
|
||||
|
||||
<!-- 7-day window bar -->
|
||||
<LinearLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:orientation="horizontal"
|
||||
android:gravity="center_vertical"
|
||||
android:layout_marginTop="10dp">
|
||||
|
||||
<TextView
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="1"
|
||||
android:text="WEEKLY"
|
||||
android:textColor="#555555"
|
||||
android:textSize="9sp"
|
||||
android:textStyle="bold" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/tv_weekly_value"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="—"
|
||||
android:textColor="#FFFFFF"
|
||||
android:textSize="13sp"
|
||||
android:textStyle="bold" />
|
||||
|
||||
</LinearLayout>
|
||||
|
||||
<ProgressBar
|
||||
android:id="@+id/progress_bar_weekly"
|
||||
style="@android:style/Widget.ProgressBar.Horizontal"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="5dp"
|
||||
android:layout_marginTop="5dp"
|
||||
android:max="100"
|
||||
android:progress="0"
|
||||
android:progressTint="#7B8FCC"
|
||||
android:progressBackgroundTint="#252525" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/tv_weekly_label"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginTop="3dp"
|
||||
android:text=""
|
||||
android:textColor="#666666"
|
||||
android:textSize="9sp" />
|
||||
|
||||
<!-- Footer -->
|
||||
<LinearLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:orientation="horizontal"
|
||||
android:layout_marginTop="8dp"
|
||||
android:gravity="center_vertical">
|
||||
|
||||
<TextView
|
||||
android:id="@+id/tv_status"
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_weight="1"
|
||||
android:text=""
|
||||
android:textColor="#CC785C"
|
||||
android:textSize="9sp"
|
||||
android:singleLine="true"
|
||||
android:ellipsize="end" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/tv_updated"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:text=""
|
||||
android:textColor="#444444"
|
||||
android:textSize="9sp" />
|
||||
|
||||
</LinearLayout>
|
||||
|
||||
</LinearLayout>
|
||||
Reference in New Issue
Block a user