Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions services_app/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -121,6 +121,7 @@ dependencies {
implementation 'commons-fileupload:commons-fileupload:1.5'
implementation 'org.opendatakit:odkx-rest-interface:2.2.0-SNAPSHOT'

implementation 'androidx.core:core-splashscreen:1.0.1'
implementation 'androidx.annotation:annotation:1.7.1'
implementation 'androidx.legacy:legacy-support-v4:1.0.0'
implementation 'androidx.appcompat:appcompat:1.5.1'
Expand Down
2 changes: 1 addition & 1 deletion services_app/src/main/AndroidManifest.xml
Original file line number Diff line number Diff line change
Expand Up @@ -110,7 +110,7 @@
<activity
android:name=".MainActivity"
android:label="@string/app_name"
android:theme="@style/ODKX">
android:theme="@style/SplashTheme">

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Why change the complete Services style?

Copy link
Author

@Femimat Femimat Oct 22, 2024

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hi @Redeem-Grimm-Satoshi
The Android documentation recommends setting the Main Activity's theme to the one created specifically for the Splash Screen

This is required because the Splash Screen theme must be applied to the Main Activity to display the Splash Screen when the app launches. After the Splash Screen is dismissed, the Main Activity’s theme will automatically switch to @style/ODKX, as defined by the postSplashScreenTheme attribute within the @style/SplashScreen theme.

<intent-filter>
<action android:name="android.intent.action.MAIN" />

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -33,6 +33,7 @@
import androidx.appcompat.app.AppCompatActivity;
import androidx.appcompat.widget.Toolbar;
import androidx.core.app.ActivityCompat;
import androidx.core.splashscreen.SplashScreen;
import androidx.core.view.GravityCompat;
import androidx.drawerlayout.widget.DrawerLayout;
import androidx.lifecycle.LifecycleEventObserver;
Expand Down Expand Up @@ -203,6 +204,7 @@ public boolean onNavigationItemSelected(MenuItem item) {

@Override
protected void onCreate(Bundle savedInstanceState) {
SplashScreen.installSplashScreen(this);
super.onCreate(savedInstanceState);
setContentView(R.layout.activity_main);

Expand Down
214 changes: 214 additions & 0 deletions services_app/src/main/res/drawable-night/odkx_splash.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,214 @@
<vector xmlns:android="http://schemas.android.com/apk/res/android"
android:width="288dp"
android:height="288dp"
android:viewportWidth="600"
android:viewportHeight="240">
<group android:scaleX="0.55"
android:scaleY="0.22"
android:translateX="135"
android:translateY="93.6">
<group>
<path
android:pathData="M400,200L560,40"
android:strokeWidth="38"
android:fillColor="#3E77B4"
android:strokeColor="#FFFFFF"
android:fillType="evenOdd"
android:strokeLineCap="round"/>
<path
android:pathData="M400,40L560,200"
android:strokeWidth="38"
android:fillColor="#3E77B4"
android:strokeColor="#FFFFFF"
android:fillType="evenOdd"
android:strokeLineCap="round"/>
<path
android:pathData="M400,200L560,40"
android:strokeWidth="30"
android:fillColor="#3E77B4"
android:strokeColor="#DF961F"
android:fillType="evenOdd"
android:strokeLineCap="round"/>
<path
android:pathData="M400,40L560,200"
android:strokeWidth="30"
android:fillColor="#3E77B4"
android:strokeColor="#DF961F"
android:fillType="evenOdd"
android:strokeLineCap="round"/>
<path
android:pathData="M375,120L415,120"
android:strokeWidth="30"
android:fillColor="#3E77B4"
android:strokeColor="#FFFFFF"
android:fillType="evenOdd"
android:strokeLineCap="round"/>
<path
android:pathData="M375,120L415,120"
android:strokeWidth="24"
android:fillColor="#3E77B4"
android:strokeColor="#686768"
android:fillType="evenOdd"
android:strokeLineCap="round"/>
<path
android:pathData="M300,200L300,40"
android:strokeWidth="38"
android:fillColor="#3E77B4"
android:strokeColor="#FFFFFF"
android:fillType="evenOdd"
android:strokeLineCap="round"/>
<path
android:pathData="M300,120L400,40"
android:strokeWidth="38"
android:fillColor="#3E77B4"
android:strokeColor="#FFFFFF"
android:fillType="evenOdd"
android:strokeLineCap="round"/>
<path
android:pathData="M300,120L400,200"
android:strokeWidth="38"
android:fillColor="#3E77B4"
android:strokeColor="#FFFFFF"
android:fillType="evenOdd"
android:strokeLineCap="round"/>
<path
android:pathData="M300,200L300,40"
android:strokeWidth="30"
android:fillColor="#3E77B4"
android:strokeColor="#0A711E"
android:fillType="evenOdd"
android:strokeLineCap="round"/>
<path
android:pathData="M300,120L400,40"
android:strokeWidth="30"
android:fillColor="#3E77B4"
android:strokeColor="#0A711E"
android:fillType="evenOdd"
android:strokeLineCap="round"/>
<path
android:pathData="M300,120L400,200"
android:strokeWidth="30"
android:fillColor="#3E77B4"
android:strokeColor="#0A711E"
android:fillType="evenOdd"
android:strokeLineCap="round"/>
<path
android:pathData="M200,200L200,40"
android:strokeWidth="38"
android:fillColor="#3E77B4"
android:strokeColor="#FFFFFF"
android:fillType="evenOdd"
android:strokeLineCap="round"/>
<path
android:pathData="M200,200L300,120"
android:strokeWidth="38"
android:fillColor="#3E77B4"
android:strokeColor="#FFFFFF"
android:fillType="evenOdd"
android:strokeLineCap="round"/>
<path
android:pathData="M200,40L300,120"
android:strokeWidth="38"
android:fillColor="#3E77B4"
android:strokeColor="#FFFFFF"
android:fillType="evenOdd"
android:strokeLineCap="round"/>
<path
android:pathData="M200,200L200,40"
android:strokeWidth="30"
android:fillColor="#3E77B4"
android:strokeColor="#904A22"
android:fillType="evenOdd"
android:strokeLineCap="round"/>
<path
android:pathData="M200,200L300,120"
android:strokeWidth="30"
android:fillColor="#3E77B4"
android:strokeColor="#904A22"
android:fillType="evenOdd"
android:strokeLineCap="round"/>
<path
android:pathData="M200,40L300,120"
android:strokeWidth="30"
android:fillColor="#3E77B4"
android:strokeColor="#904A22"
android:fillType="evenOdd"
android:strokeLineCap="round"/>
<path
android:pathData="M120,40L200,120"
android:strokeWidth="39"
android:fillColor="#3E77B4"
android:strokeColor="#FFFFFF"
android:fillType="evenOdd"
android:strokeLineCap="round"/>
<path
android:pathData="M40,120L120,200"
android:strokeWidth="39"
android:fillColor="#3E77B4"
android:strokeColor="#FFFFFF"
android:fillType="evenOdd"
android:strokeLineCap="round"/>
<path
android:pathData="M40,120L120,40"
android:strokeWidth="39"
android:fillColor="#3E77B4"
android:strokeColor="#FFFFFF"
android:fillType="evenOdd"
android:strokeLineCap="round"/>
<path
android:pathData="M120,200L200,120"
android:strokeWidth="39"
android:fillColor="#3E77B4"
android:strokeColor="#FFFFFF"
android:fillType="evenOdd"
android:strokeLineCap="round"/>
<path
android:pathData="M120,40L200,120"
android:strokeWidth="30"
android:fillColor="#3E77B4"
android:strokeColor="#3E77B4"
android:fillType="evenOdd"
android:strokeLineCap="round"/>
<path
android:pathData="M40,120L120,200"
android:strokeWidth="30"
android:fillColor="#3E77B4"
android:strokeColor="#3E77B4"
android:fillType="evenOdd"
android:strokeLineCap="round"/>
<path
android:pathData="M40,120L120,40"
android:strokeWidth="30"
android:fillColor="#3E77B4"
android:strokeColor="#3E77B4"
android:fillType="evenOdd"
android:strokeLineCap="round"/>
<path
android:pathData="M120,200L200,120"
android:strokeWidth="30"
android:fillColor="#3E77B4"
android:strokeColor="#3E77B4"
android:fillType="evenOdd"
android:strokeLineCap="round"/>
</group>

<group android:translateY="350">
<path android:pathData="M46.195312,2.390625Q57.515625,2.390625,65.953125,-1.3710938Q74.390625,-5.1328125,79.03125,-12.0234375Q83.671875,-18.914062,83.671875,-28.40625L83.671875,-28.476562Q83.671875,-35.789062,80.68359,-41.16797Q77.69531,-46.546875,71.22656,-50.273438Q64.75781,-54,54.140625,-56.320312L42.890625,-58.851562Q36,-60.398438,31.746094,-62.71875Q27.492188,-65.03906,25.523438,-68.23828Q23.554688,-71.4375,23.554688,-75.44531L23.554688,-75.515625Q23.554688,-80.859375,26.542969,-84.55078Q29.53125,-88.24219,34.59375,-90.21094Q39.65625,-92.17969,45.984375,-92.17969Q52.59375,-92.25,57.515625,-90.21094Q62.4375,-88.171875,65.390625,-84.69141Q68.34375,-81.21094,69.046875,-76.71094L69.1875,-75.796875L81.84375,-75.796875L81.77344,-76.78125Q81.28125,-84.375,76.67578,-90.49219Q72.07031,-96.609375,64.265625,-100.23047Q56.460938,-103.85156,46.335938,-103.85156Q35.859375,-103.85156,27.808594,-100.19531Q19.757812,-96.53906,15.222656,-90.07031Q10.6875,-83.60156,10.6171875,-75.16406L10.6171875,-75.09375Q10.6171875,-67.78125,13.675781,-62.191406Q16.734375,-56.601562,23.167969,-52.69922Q29.601562,-48.796875,39.726562,-46.546875L50.976562,-44.085938Q61.453125,-41.765625,66.09375,-37.441406Q70.734375,-33.117188,70.734375,-26.789062L70.734375,-26.71875Q70.734375,-21.585938,67.640625,-17.648438Q64.546875,-13.7109375,59.16797,-11.496094Q53.789062,-9.28125,46.898438,-9.28125Q39.585938,-9.28125,33.85547,-11.3203125Q28.125,-13.359375,24.714844,-17.050781Q21.304688,-20.742188,20.8125,-25.804688L20.742188,-26.578125L8.0859375,-26.578125L8.15625,-25.804688Q8.9296875,-17.578125,13.746094,-11.214844Q18.5625,-4.8515625,26.824219,-1.2304688Q35.085938,2.390625,46.195312,2.390625Z"
android:fillColor="#DF961F"/>
<path android:pathData="M134.32812,1.3359375Q141.00781,1.3359375,146.38672,-0.38671875Q151.76562,-2.109375,155.70312,-5.0273438Q159.64062,-7.9453125,162.13672,-11.566406Q164.63281,-15.1875,165.61719,-19.054688L165.75781,-19.617188L153.52344,-19.617188L153.24219,-18.984375Q152.25781,-16.734375,149.79688,-14.5546875Q147.33594,-12.375,143.53906,-10.96875Q139.74219,-9.5625,134.60938,-9.5625Q127.71875,-9.5625,122.65625,-12.621094Q117.59375,-15.6796875,114.85156,-21.410156Q112.109375,-27.140625,112.109375,-35.226562L112.109375,-40.078125Q112.109375,-48.585938,114.921875,-54.421875Q117.734375,-60.257812,122.55078,-63.246094Q127.36719,-66.234375,133.48438,-66.234375Q139.60156,-66.234375,144.3125,-63.38672Q149.02344,-60.539062,151.69531,-54.773438Q154.36719,-49.007812,154.36719,-40.078125L154.36719,-35.226562L160.41406,-44.15625L105.921875,-44.15625L105.921875,-34.382812L166.67188,-34.382812L166.67188,-39.164062Q166.67188,-50.484375,162.69922,-59.027344Q158.72656,-67.57031,151.3086,-72.35156Q143.89062,-77.13281,133.55469,-77.13281Q123.28906,-77.13281,115.625,-72.140625Q107.96094,-67.14844,103.77734,-58.289062Q99.59375,-49.429688,99.59375,-37.6875L99.59375,-37.617188Q99.59375,-25.734375,103.77734,-16.980469Q107.96094,-8.2265625,115.73047,-3.4453125Q123.5,1.3359375,134.32812,1.3359375Z"
android:fillColor="#DF961F"/>
<path android:pathData="M185.39062,0L197.625,0L197.625,-46.96875Q197.625,-52.523438,200.1914,-56.671875Q202.75781,-60.820312,207.25781,-63.140625Q211.75781,-65.46094,217.59375,-65.46094Q219.63281,-65.46094,221.42578,-65.28516Q223.21875,-65.109375,225.11719,-64.75781L225.11719,-76.640625Q224.20312,-76.78125,222.48047,-76.95703Q220.75781,-77.13281,219,-77.13281Q211.33594,-77.13281,206.13281,-73.828125Q200.92969,-70.52344,198.75,-64.546875L197.625,-64.546875L197.625,-75.796875L185.39062,-75.796875Z"
android:fillColor="#DF961F"/>
<path android:pathData="M261.83594,0L274.21094,0L302.26562,-75.796875L289.32812,-75.796875L268.58594,-13.359375L267.46094,-13.359375L246.71875,-75.796875L233.78125,-75.796875Z"
android:fillColor="#DF961F"/>
<path android:pathData="M318.67188,0L330.90625,0L330.90625,-75.796875L318.67188,-75.796875ZM324.85938,-90.421875Q328.375,-90.421875,330.83594,-92.91797Q333.29688,-95.41406,333.29688,-98.859375Q333.29688,-102.375,330.83594,-104.83594Q328.375,-107.296875,324.85938,-107.296875Q321.41406,-107.296875,318.91797,-104.83594Q316.42188,-102.375,316.42188,-98.859375Q316.42188,-95.41406,318.91797,-92.91797Q321.41406,-90.421875,324.85938,-90.421875Z"
android:fillColor="#DF961F"/>
<path android:pathData="M385.39844,1.3359375Q394.53906,1.3359375,401.0078,-1.6875Q407.47656,-4.7109375,411.41406,-10.019531Q415.35156,-15.328125,416.89844,-22.148438L417.03906,-22.921875L404.9453,-22.851562L404.8047,-22.429688Q402.6953,-16.101562,397.84375,-12.796875Q392.9922,-9.4921875,385.32812,-9.4921875Q378.57812,-9.4921875,373.58594,-13.0078125Q368.59375,-16.523438,365.85156,-22.957031Q363.10938,-29.390625,363.10938,-38.109375L363.10938,-38.25Q363.10938,-46.828125,365.8164,-53.121094Q368.52344,-59.414062,373.51562,-62.859375Q378.5078,-66.30469,385.32812,-66.30469Q393.48438,-66.30469,398.47656,-62.367188Q403.46875,-58.429688,404.875,-52.804688L404.9453,-52.59375L417.10938,-52.59375L417.03906,-53.015625Q415.91406,-59.765625,411.90625,-65.21484Q407.89844,-70.66406,401.21875,-73.89844Q394.53906,-77.13281,385.32812,-77.13281Q374.71094,-77.13281,366.90625,-72.31641Q359.10156,-67.5,354.84766,-58.78125Q350.59375,-50.0625,350.59375,-38.25L350.59375,-38.109375Q350.59375,-26.085938,354.8828,-17.226562Q359.17188,-8.3671875,366.97656,-3.515625Q374.78125,1.3359375,385.39844,1.3359375Z"
android:fillColor="#DF961F"/>
<path android:pathData="M466.32812,1.3359375Q473.0078,1.3359375,478.38672,-0.38671875Q483.76562,-2.109375,487.70312,-5.0273438Q491.64062,-7.9453125,494.13672,-11.566406Q496.6328,-15.1875,497.6172,-19.054688L497.7578,-19.617188L485.52344,-19.617188L485.2422,-18.984375Q484.2578,-16.734375,481.79688,-14.5546875Q479.33594,-12.375,475.53906,-10.96875Q471.7422,-9.5625,466.60938,-9.5625Q459.71875,-9.5625,454.65625,-12.621094Q449.59375,-15.6796875,446.85156,-21.410156Q444.10938,-27.140625,444.10938,-35.226562L444.10938,-40.078125Q444.10938,-48.585938,446.92188,-54.421875Q449.73438,-60.257812,454.55078,-63.246094Q459.3672,-66.234375,465.48438,-66.234375Q471.60156,-66.234375,476.3125,-63.38672Q481.02344,-60.539062,483.6953,-54.773438Q486.3672,-49.007812,486.3672,-40.078125L486.3672,-35.226562L492.41406,-44.15625L437.92188,-44.15625L437.92188,-34.382812L498.67188,-34.382812L498.67188,-39.164062Q498.67188,-50.484375,494.69922,-59.027344Q490.72656,-67.57031,483.3086,-72.35156Q475.89062,-77.13281,465.5547,-77.13281Q455.28906,-77.13281,447.625,-72.140625Q439.96094,-67.14844,435.77734,-58.289062Q431.59375,-49.429688,431.59375,-37.6875L431.59375,-37.617188Q431.59375,-25.734375,435.77734,-16.980469Q439.96094,-8.2265625,447.73047,-3.4453125Q455.5,1.3359375,466.32812,1.3359375Z"
android:fillColor="#DF961F"/>
<path android:pathData="M543.40625,1.3359375Q552.0547,1.3359375,558.91016,-1.546875Q565.7656,-4.4296875,569.77344,-9.597656Q573.78125,-14.765625,573.78125,-21.515625L573.78125,-21.65625Q573.78125,-27.070312,571.46094,-31.007812Q569.1406,-34.945312,564.46484,-37.6875Q559.78906,-40.429688,552.6172,-42.117188L540.9453,-44.929688Q536.5156,-46.054688,533.7031,-47.53125Q530.8906,-49.007812,529.5547,-50.976562Q528.21875,-52.945312,528.21875,-55.476562L528.21875,-55.617188Q528.21875,-58.992188,530.2578,-61.523438Q532.2969,-64.05469,535.8125,-65.49609Q539.3281,-66.9375,543.8281,-66.9375Q550.71875,-66.9375,555.0078,-64.125Q559.2969,-61.3125,560.4922,-56.8125L560.4922,-56.8125L572.5156,-56.8125L572.5156,-56.8125Q571.6719,-63,567.91016,-67.57031Q564.14844,-72.140625,557.9961,-74.63672Q551.84375,-77.13281,543.89844,-77.13281Q535.8828,-77.13281,529.4844,-74.25Q523.08594,-71.36719,519.39453,-66.375Q515.7031,-61.382812,515.7031,-55.054688L515.7031,-54.984375Q515.7031,-49.570312,517.8828,-45.597656Q520.0625,-41.625,524.6328,-38.91797Q529.2031,-36.210938,536.3047,-34.523438L548.0469,-31.710938Q555.0781,-30.023438,558.1719,-27.316406Q561.2656,-24.609375,561.2656,-20.742188L561.2656,-20.601562Q561.2656,-17.15625,559.0156,-14.519531Q556.7656,-11.8828125,552.8633,-10.371094Q548.96094,-8.859375,543.8281,-8.859375Q536.58594,-8.859375,532.08594,-11.7421875Q527.58594,-14.625,526.03906,-19.335938L526.03906,-19.335938L513.52344,-19.335938L513.52344,-19.335938Q514.22656,-13.078125,518.1289,-8.4375Q522.03125,-3.796875,528.5,-1.2304688Q534.96875,1.3359375,543.40625,1.3359375Z"
android:fillColor="#DF961F"/>
</group>
</group>
</vector>
Loading