Skip to content

Commit

Permalink
Update sample app links
Browse files Browse the repository at this point in the history
  • Loading branch information
pranavpandey committed Jun 16, 2022
1 parent 0059c19 commit c168e53
Show file tree
Hide file tree
Showing 8 changed files with 104 additions and 27 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -45,6 +45,11 @@ object Constants {
*/
const val PACKAGE_PALETTES = "com.pranavpandey.theme"

/**
* Barquode package name.
*/
const val PACKAGE_BARQUODE = "com.pranavpandey.matrix"

/**
* Zerocros package name.
*/
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -88,31 +88,38 @@ class HomeFragment : DynamicFragment() {

// Set on click listener for the dynamic item view.
(view.findViewById<View>(R.id.item_rotation) as DynamicItemView)
.setOnClickListener {
// View an app in Google Play by supplying the package name.
DynamicLinkUtils.viewInGooglePlay(requireContext(), Constants.PACKAGE_ROTATION)
}
.setOnClickListener {
// View an app in Google Play by supplying the package name.
DynamicLinkUtils.viewInGooglePlay(requireContext(), Constants.PACKAGE_ROTATION)
}

// Set on click listener for the dynamic item view.
(view.findViewById<View>(R.id.item_everyday) as DynamicItemView)
.setOnClickListener {
// View an app in Google Play by supplying the package name.
DynamicLinkUtils.viewInGooglePlay(requireContext(), Constants.PACKAGE_EVERYDAY)
}
.setOnClickListener {
// View an app in Google Play by supplying the package name.
DynamicLinkUtils.viewInGooglePlay(requireContext(), Constants.PACKAGE_EVERYDAY)
}

// Set on click listener for the dynamic item view.
(view.findViewById<View>(R.id.item_palettes) as DynamicItemView)
.setOnClickListener {
// View an app in Google Play by supplying the package name.
DynamicLinkUtils.viewInGooglePlay(requireContext(), Constants.PACKAGE_PALETTES)
}
.setOnClickListener {
// View an app in Google Play by supplying the package name.
DynamicLinkUtils.viewInGooglePlay(requireContext(), Constants.PACKAGE_PALETTES)
}

// Set on click listener for the dynamic item view.
(view.findViewById<View>(R.id.item_barquode) as DynamicItemView)
.setOnClickListener {
// View an app in Google Play by supplying the package name.
DynamicLinkUtils.viewInGooglePlay(requireContext(), Constants.PACKAGE_BARQUODE)
}

// Set on click listener for the dynamic item view.
(view.findViewById<View>(R.id.item_zerocors) as DynamicItemView)
.setOnClickListener {
// View an app in Google Play by supplying the package name.
DynamicLinkUtils.viewInGooglePlay(requireContext(), Constants.PACKAGE_ZEROCROS)
}
.setOnClickListener {
// View an app in Google Play by supplying the package name.
DynamicLinkUtils.viewInGooglePlay(requireContext(), Constants.PACKAGE_ZEROCROS)
}

// Set on preference click listeners.
// Start tutorial activity.
Expand Down
49 changes: 49 additions & 0 deletions sample/src/main/res/drawable/ic_barquode.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,49 @@
<?xml version="1.0" encoding="utf-8"?>
<!--
Copyright 2021-2022 Pranav Pandey
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.
-->

<vector
xmlns:android="http://schemas.android.com/apk/res/android"
android:width="24dp"
android:height="24dp"
android:viewportWidth="108"
android:viewportHeight="108">

<path
android:fillColor="#81D4FA"
android:pathData="m12.02 4.43h83.95c4.19 0 7.59 3.4 7.59 7.59v83.95c0 4.19 -3.4 7.59 -7.59 7.59h-83.95c-4.19 0 -7.59 -3.4 -7.59 -7.59v-83.95c0 -4.19 3.4 -7.59 7.59 -7.59z" />

<path
android:name="path_scan"
android:fillColor="#000000"
android:pathData="m68.14 68.35v6.14h3.03v-3.11h3.11v-3.03zm6.06 6.06v0.08h0.08v-0.08zm11.42 0v0.08h0.08v-0.08zm0 -6.06v3.03h3.11v3.11h3.03v-6.14zm-11.42 17.48v0.08h0.08v-0.08zm11.42 0v0.08h0.08v-0.08zm-17.48 0v6.14h6.14v-3.03h-3.11v-3.11zm20.59 0v3.11h-3.11v3.03h6.14v-6.14z"
android:fillAlpha="@dimen/adt_fill_alpha_medium" />

<path
android:fillColor="#000000"
android:pathData="m26.93 40.18v16.94h3.95v-16.94zm7.91 0v16.94h2.37v-16.94zm7.91 0v16.94h3.95v-16.94zm18.58 0v16.94h3.95v-16.94zm9.49 0v16.94h2.37v-16.94zm6.33 0v16.94h3.95v-16.94zm-58.11 0v19.77h2.37v-19.77zm31.63 0v19.77h1.58v-19.77zm5.14 0v19.77h1.58v-19.77zm30.83 0v19.77h2.37v-19.77z"
android:fillAlpha="@dimen/adt_fill_alpha_secondary" />

<group
android:name="group_finder">

<path
android:fillColor="#AB47BC"
android:pathData="m20.17 20.17v7.87h7.87v-7.87zm59.78 0v7.87h7.87v-7.87zm-49.84 -2.07v12.01h-12.01v-12.01zm59.78 0v12.01h-12.01v-12.01zm-73.87 -2.07v16.16h16.16v-16.16zm59.78 0v16.16h16.16v-16.16zm-55.64 63.92v7.87h7.87v-7.87zm9.94 -2.07v12.01h-12.01v-12.01zm-14.09 -2.07v16.16h16.16v-16.16z" />

</group>

</vector>
2 changes: 1 addition & 1 deletion sample/src/main/res/drawable/ic_everyday.xml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<?xml version="1.0" encoding="utf-8"?>
<!--
Copyright 2019-2021 Pranav Pandey
Copyright 2019-2022 Pranav Pandey
Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
Expand Down
2 changes: 1 addition & 1 deletion sample/src/main/res/drawable/ic_rotation.xml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<?xml version="1.0" encoding="utf-8"?>
<!--
Copyright 2017-2021 Pranav Pandey
Copyright 2017-2022 Pranav Pandey
Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
Expand Down
10 changes: 5 additions & 5 deletions sample/src/main/res/drawable/ic_zerocros.xml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<?xml version="1.0" encoding="utf-8"?>
<!--
Copyright 2021 Pranav Pandey
Copyright 2021-2022 Pranav Pandey
Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
Expand All @@ -24,19 +24,19 @@

<path
android:fillColor="#795548"
android:pathData="m14.98 4.43h78.68c5.59 0 10.13 4.53 10.13 10.13v78.89c0 5.59 -4.53 10.13 -10.13 10.13h-78.68c-5.59 0 -10.13 -4.53 -10.13 -10.13v-78.89c0 -5.59 4.53 -10.13 10.13 -10.13z" />
android:pathData="m12.02 4.43h83.95c4.19 0 7.59 3.4 7.59 7.59v83.95c0 4.19 -3.4 7.59 -7.59 7.59h-83.95c-4.19 0 -7.59 -3.4 -7.59 -7.59v-83.95c0 -4.19 3.4 -7.59 7.59 -7.59z" />

<path
android:fillColor="@color/adt_icon_fill_light"
android:pathData="m68.55 39.45v28.9h-28.9v-28.9zm-34.8 -35.02v29.11h-28.9v5.91h28.9v28.9h-28.9v5.91h28.9v29.32h5.91v-29.32h28.9v29.32h5.91v-29.32h29.32v-5.91h-29.32v-28.9h29.32v-5.91h-29.32v-29.11h-5.91v29.11h-28.9v-29.11z"
android:pathData="m68.63 39.29v28.79h-28.84v-28.79zm-34.74 -34.86v28.98h-29.47v5.88h29.47v28.79h-29.47v5.88h29.47v29.61h5.89v-29.61h28.84v29.61h5.89v-29.61h29.04v-5.88h-29.04v-28.79h29.04v-5.88h-29.04v-28.98h-5.89v28.98h-28.84v-28.98z"
android:fillAlpha="@dimen/adt_fill_alpha_base" />

<path
android:fillColor="#00E676"
android:pathData="m23.86 48.81c3.53 3.45 7.81 5.18 12.83 5.18c5.1 0 9.4 -1.71 12.9 -5.14c3.5 -3.43 5.26 -7.63 5.26 -12.6c0 -4.69 -1.77 -8.74 -5.32 -12.16c-3.55 -3.41 -7.77 -5.12 -12.68 -5.12c-5.03 0 -9.33 1.69 -12.91 5.08c-3.58 3.39 -5.37 7.45 -5.37 12.19c0 4.92 1.76 9.1 5.29 12.56zm22.35 -3.32c-2.57 2.53 -5.63 3.8 -9.18 3.8c-3.86 0 -7.11 -1.24 -9.77 -3.72c-2.66 -2.48 -3.99 -5.52 -3.99 -9.11c0 -3.54 1.3 -6.57 3.89 -9.1c2.59 -2.53 5.7 -3.79 9.34 -3.79c3.82 0 7.04 1.24 9.66 3.72c2.62 2.48 3.93 5.54 3.93 9.16c0 3.49 -1.29 6.5 -3.86 9.03z" />
android:pathData="m23.86 48.6c3.53 3.45 7.81 5.18 12.83 5.18c5.1 0 9.4 -1.71 12.9 -5.14c3.5 -3.43 5.26 -7.63 5.26 -12.6c0 -4.69 -1.77 -8.74 -5.32 -12.16c-3.55 -3.41 -7.77 -5.12 -12.68 -5.12c-5.03 0 -9.33 1.69 -12.91 5.08c-3.58 3.39 -5.37 7.45 -5.37 12.19c0 4.92 1.76 9.1 5.29 12.56zm22.35 -3.32c-2.57 2.53 -5.63 3.8 -9.18 3.8c-3.86 0 -7.11 -1.24 -9.77 -3.72c-2.66 -2.48 -3.99 -5.52 -3.99 -9.11c0 -3.54 1.3 -6.57 3.89 -9.1c2.59 -2.53 5.7 -3.79 9.34 -3.79c3.82 0 7.04 1.24 9.66 3.72c2.62 2.48 3.93 5.54 3.93 9.16c0 3.49 -1.29 6.5 -3.86 9.03z" />

<path
android:fillColor="#4DD0E1"
android:pathData="m60.2 56.32c-0.12 0 -0.23 0.04 -0.32 0.13l-3.21 3.21c-0.18 0.18 -0.18 0.47 0 0.64l11.09 11.09l-11.09 11.09c-0.18 0.18 -0.18 0.47 0 0.64l3.21 3.21c0.09 0.09 0.21 0.13 0.32 0.13c0.12 0 0.23 -0.04 0.32 -0.13l11.09 -11.09l11.09 11.09c0.09 0.09 0.21 0.13 0.32 0.13c0.12 0 0.23 -0.04 0.32 -0.13l3.21 -3.21c0.18 -0.18 0.18 -0.47 0 -0.64l-11.09 -11.09l11.09 -11.09c0.18 -0.18 0.18 -0.47 0 -0.64l-3.21 -3.21c-0.09 -0.09 -0.21 -0.13 -0.32 -0.13c-0.12 0 -0.23 0.04 -0.32 0.13l-11.09 11.09l-11.09 -11.09c-0.09 -0.09 -0.21 -0.13 -0.32 -0.13z" />
android:pathData="m60.41 55.9c-0.12 0 -0.23 0.04 -0.32 0.13l-3.21 3.21c-0.18 0.18 -0.18 0.47 0 0.64l11.09 11.09l-11.09 11.09c-0.18 0.18 -0.18 0.47 0 0.64l3.21 3.21c0.09 0.09 0.21 0.13 0.32 0.13c0.12 0 0.23 -0.04 0.32 -0.13l11.09 -11.09l11.09 11.09c0.09 0.09 0.21 0.13 0.32 0.13c0.12 0 0.23 -0.04 0.32 -0.13l3.21 -3.21c0.18 -0.18 0.18 -0.47 0 -0.64l-11.09 -11.09l11.09 -11.09c0.18 -0.18 0.18 -0.47 0 -0.64l-3.21 -3.21c-0.09 -0.09 -0.21 -0.13 -0.32 -0.13c-0.12 0 -0.23 0.04 -0.32 0.13l-11.09 11.09l-11.09 -11.09c-0.09 -0.09 -0.21 -0.13 -0.32 -0.13z" />

</vector>
14 changes: 14 additions & 0 deletions sample/src/main/res/layout/fragment_home.xml
Original file line number Diff line number Diff line change
Expand Up @@ -123,6 +123,20 @@

</com.pranavpandey.android.dynamic.support.widget.DynamicCardView>

<com.pranavpandey.android.dynamic.support.widget.DynamicCardView
style="@style/Widget.DynamicApp.Card">

<com.pranavpandey.android.dynamic.support.view.base.DynamicItemView
android:id="@+id/item_barquode"
android:layout_width="match_parent"
android:layout_height="wrap_content"
app:ads_icon="@drawable/ic_barquode"
app:ads_title="@string/barquode"
app:ads_subtitle="@string/barquode_subtitle"
app:adt_colorType="none" />

</com.pranavpandey.android.dynamic.support.widget.DynamicCardView>

<com.pranavpandey.android.dynamic.support.widget.DynamicCardView
style="@style/Widget.DynamicApp.Card">

Expand Down
10 changes: 6 additions & 4 deletions sample/src/main/res/values/strings.xml
Original file line number Diff line number Diff line change
Expand Up @@ -43,13 +43,15 @@
<string name="collapsing_app_bar_subtitle">A collapsing app bar layout by using dynamic activity.</string>
<string name="bottom_navigation">Bottom navigation</string>
<string name="bottom_navigation_subtitle">A bottom navigation view by using dynamic activity.</string>
<string name="rotation">Rotation - Orientation Manager</string>
<string name="rotation">Rotation | Orientation Manager</string>
<string name="rotation_subtitle">An app completely built by using this library. It covers some more advanced use cases like multiple locales, runtime permissions, etc. and can motivate to implement similar kind of functionality by exploring the sources of Dynamic Support.</string>
<string name="everyday">Everyday - Calendar Widget</string>
<string name="everyday">Everyday | Calendar Widget</string>
<string name="everyday_subtitle">An app to show the widget customisations by extending the app theme. It also features some more advanced use cases like multiple locales, runtime permissions, remote views factory, etc. and can motivate to implement similar kind of functionality by exploring the sources of Dynamic Support.</string>
<string name="palettes">Palettes - Theme manager</string>
<string name="palettes">Palettes | Theme manager</string>
<string name="palettes_subtitle">A universal manager for apps supporting the dynamic theme on Android. It provides some default configurations which can be extended to create custom ones. Let\'s give it a try to explore its other useful features.</string>
<string name="zerocros">Zerocros - Tic-tac-toe Game</string>
<string name="barquode">Barquode | Matrix Manager</string>
<string name="barquode_subtitle">A tool to create, capture and manage a wide variety of matrix codes including Barcodes and QR codes. It is highly customizable with a dynamic theme engine to match your style.</string>
<string name="zerocros">Zerocros | Tic-tac-toe Game</string>
<string name="zerocros_subtitle">A tic-tac-toe game set in the dynamic theme world with various customizations.</string>

<!-- Widgets -->
Expand Down

0 comments on commit c168e53

Please sign in to comment.