Commit 4b2cd782 authored by wanglei's avatar wanglei

feat:白包修改

parent 9918d474
...@@ -3,7 +3,20 @@ ...@@ -3,7 +3,20 @@
<component name="deploymentTargetDropDown"> <component name="deploymentTargetDropDown">
<value> <value>
<entry key="app"> <entry key="app">
<State /> <State>
<runningDeviceTargetSelectedWithDropDown>
<Target>
<type value="RUNNING_DEVICE_TARGET" />
<deviceKey>
<Key>
<type value="SERIAL_NUMBER" />
<value value="adb-RF9N8045MAW-sXXAeN._adb-tls-connect._tcp" />
</Key>
</deviceKey>
</Target>
</runningDeviceTargetSelectedWithDropDown>
<timeTargetWasSelectedWithDropDown value="2024-03-22T01:27:31.767940Z" />
</State>
</entry> </entry>
</value> </value>
</component> </component>
......
...@@ -36,12 +36,12 @@ suspend fun Context.queryFileCount(key: Preferences.Key<Int>, action: (count: In ...@@ -36,12 +36,12 @@ suspend fun Context.queryFileCount(key: Preferences.Key<Int>, action: (count: In
dataStore.data.map { it[EMPTY_FILE_COUNTER_KEY] } dataStore.data.map { it[EMPTY_FILE_COUNTER_KEY] }
} }
else -> null else -> flowOf(0)
} }
flow.collect {
flow?.collect {
if (it != null) { if (it != null) {
action.invoke(it) action.invoke(it)
} }
} }
} }
\ No newline at end of file
...@@ -97,6 +97,7 @@ class ToolsFragment : Fragment() { ...@@ -97,6 +97,7 @@ class ToolsFragment : Fragment() {
if (count == 0) { if (count == 0) {
binding.tvDupCout.visibility = View.GONE binding.tvDupCout.visibility = View.GONE
} else { } else {
binding.tvDupCout.visibility = View.VISIBLE
binding.tvDupCout.text = "$count items" binding.tvDupCout.text = "$count items"
} }
} }
...@@ -108,6 +109,7 @@ class ToolsFragment : Fragment() { ...@@ -108,6 +109,7 @@ class ToolsFragment : Fragment() {
if (count == 0) { if (count == 0) {
binding.tvLargeCount.visibility = View.GONE binding.tvLargeCount.visibility = View.GONE
} else { } else {
binding.tvLargeCount.visibility = View.VISIBLE
binding.tvLargeCount.text = "$count items" binding.tvLargeCount.text = "$count items"
} }
} }
...@@ -120,6 +122,7 @@ class ToolsFragment : Fragment() { ...@@ -120,6 +122,7 @@ class ToolsFragment : Fragment() {
if (dupCount == 0) { if (dupCount == 0) {
binding.tvEmptyCount.visibility = View.GONE binding.tvEmptyCount.visibility = View.GONE
} else { } else {
binding.tvEmptyCount.visibility = View.VISIBLE
binding.tvEmptyCount.text = "$dupCount items" binding.tvEmptyCount.text = "$dupCount items"
} }
} }
......
...@@ -65,6 +65,7 @@ ...@@ -65,6 +65,7 @@
tools:ignore="HardcodedText" /> tools:ignore="HardcodedText" />
<TextView <TextView
android:visibility="gone"
android:id="@+id/tv_dup_cout" android:id="@+id/tv_dup_cout"
android:layout_width="wrap_content" android:layout_width="wrap_content"
android:layout_height="wrap_content" android:layout_height="wrap_content"
...@@ -133,6 +134,7 @@ ...@@ -133,6 +134,7 @@
tools:ignore="HardcodedText" /> tools:ignore="HardcodedText" />
<TextView <TextView
android:visibility="gone"
android:id="@+id/tv_large_count" android:id="@+id/tv_large_count"
android:layout_width="wrap_content" android:layout_width="wrap_content"
android:layout_height="wrap_content" android:layout_height="wrap_content"
...@@ -202,6 +204,7 @@ ...@@ -202,6 +204,7 @@
tools:ignore="HardcodedText" /> tools:ignore="HardcodedText" />
<TextView <TextView
android:visibility="gone"
android:id="@+id/tv_empty_count" android:id="@+id/tv_empty_count"
android:layout_width="wrap_content" android:layout_width="wrap_content"
android:layout_height="wrap_content" android:layout_height="wrap_content"
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment