Skip to content

Commit 57fc251

Browse files
committed
Migrate project to androidX
1 parent 56c8137 commit 57fc251

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

41 files changed

+568
-455
lines changed

.gitignore

+85-1
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,91 @@
1+
*.iml
12
.gradle
23
/local.properties
3-
/.idea/workspace.xml
4+
/.idea/caches
45
/.idea/libraries
6+
/.idea/modules.xml
7+
/.idea/workspace.xml
8+
/.idea/navEditor.xml
9+
/.idea/assetWizardSettings.xml
510
.DS_Store
611
/build
712
/captures
13+
.externalNativeBuild
14+
15+
# Built application files
16+
*.apk
17+
*.ap_
18+
*.aab
19+
20+
# Files for the ART/Dalvik VM
21+
*.dex
22+
23+
# Java class files
24+
*.class
25+
26+
# Generated files
27+
bin/
28+
gen/
29+
out/
30+
31+
# Gradle files
32+
.gradle/
33+
build/
34+
35+
# Local configuration file (sdk path, etc)
36+
local.properties
37+
38+
# Proguard folder generated by Eclipse
39+
proguard/
40+
41+
# Log Files
42+
*.log
43+
44+
# Android Studio Navigation editor temp files
45+
.navigation/
46+
47+
# Android Studio captures folder
48+
captures/
49+
50+
# IntelliJ
51+
*.iml
52+
.idea/workspace.xml
53+
.idea/tasks.xml
54+
.idea/gradle.xml
55+
.idea/
56+
.idea/libraries
57+
.idea/caches
58+
.idea
59+
60+
# Keystore files
61+
# Uncomment the following lines if you do not want to check your keystore files in.
62+
#*.jks
63+
#*.keystore
64+
65+
# External native build folder generated in Android Studio 2.2 and later
66+
.externalNativeBuild
67+
68+
# Google Services (e.g. APIs or Firebase)
69+
# google-services.json
70+
71+
# Freeline
72+
freeline.py
73+
freeline/
74+
freeline_project_description.json
75+
76+
# fastlane
77+
fastlane/report.xml
78+
fastlane/Preview.html
79+
fastlane/screenshots
80+
fastlane/test_output
81+
fastlane/readme.md
82+
83+
# Version control
84+
vcs.xml
85+
86+
# lint
87+
lint/intermediates/
88+
lint/generated/
89+
lint/outputs/
90+
lint/tmp/
91+
# lint/reports/

Qart.iml

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
<?xml version="1.0" encoding="UTF-8"?>
2-
<module external.linked.project.id="Qart" external.linked.project.path="$MODULE_DIR$" external.root.project.path="$MODULE_DIR$" external.system.id="GRADLE" external.system.module.group="" external.system.module.version="unspecified" type="JAVA_MODULE" version="4">
2+
<module external.linked.project.id="Qart" external.linked.project.path="$MODULE_DIR$" external.root.project.path="$MODULE_DIR$" external.system.id="GRADLE" type="JAVA_MODULE" version="4">
33
<component name="FacetManager">
44
<facet type="java-gradle" name="Java-Gradle">
55
<configuration>

app/app.iml

+97-75
Large diffs are not rendered by default.

app/build.gradle

+23-24
Original file line numberDiff line numberDiff line change
@@ -1,13 +1,12 @@
11
apply plugin: 'com.android.application'
22

33
android {
4-
compileSdkVersion 23
5-
buildToolsVersion "23.0.2"
4+
compileSdkVersion sdk_compile_version
65

76
defaultConfig {
87
applicationId "io.github.scola.qart"
9-
minSdkVersion 14
10-
targetSdkVersion 23
8+
minSdkVersion sdk_min_version
9+
targetSdkVersion sdk_target_version
1110
versionCode 14
1211
versionName "2.3"
1312
}
@@ -29,27 +28,27 @@ android {
2928
// }
3029
// }
3130

32-
applicationVariants.all { variant ->
33-
34-
variant.outputs.each { output ->
35-
def outputFile = output.outputFile
36-
if (outputFile != null && outputFile.name.endsWith('.apk')) {
37-
def fileName = outputFile.name.replace("app", "Qart").replace(".apk", "-${defaultConfig.versionName}.apk")
38-
output.outputFile = new File(outputFile.parent, fileName)
39-
}
40-
}
41-
}
31+
// applicationVariants.all { variant ->
32+
//
33+
// variant.outputs.each { output ->
34+
// def outputFile = output.outputFile
35+
// if (outputFile != null && outputFile.name.endsWith('.apk')) {
36+
// def fileName = outputFile.name.replace("app", "Qart").replace(".apk", "-${defaultConfig.versionName}.apk")
37+
// output.outputFile = new File(outputFile.parent, fileName)
38+
// }
39+
// }
40+
// }
4241
}
4342

4443
dependencies {
45-
compile fileTree(include: ['*.jar'], dir: 'libs')
46-
compile(name: 'colorpicker', ext: 'aar')
47-
compile 'com.android.support:appcompat-v7:23.3.0'
48-
compile 'com.google.zxing:core:3.2.1'
49-
compile 'com.journeyapps:zxing-android-embedded:3.3.0'
50-
compile 'com.github.castorflex.smoothprogressbar:library:1.1.0'
51-
compile 'pl.droidsonroids.gif:android-gif-drawable:1.2.2'
52-
compile 'com.aurelhubert:ahbottomnavigation:1.5.1'
53-
compile project(':cropper')
54-
compile project(':onboarder')
44+
implementation fileTree(include: ['*.jar'], dir: 'libs')
45+
implementation(name: 'colorpicker', ext: 'aar')
46+
implementation 'androidx.appcompat:appcompat:1.0.2'
47+
implementation 'com.google.zxing:core:3.3.3'
48+
implementation 'com.journeyapps:zxing-android-embedded:3.3.0'
49+
implementation 'com.github.castorflex.smoothprogressbar:library:1.1.0'
50+
implementation 'pl.droidsonroids.gif:android-gif-drawable:1.2.2'
51+
implementation 'com.aurelhubert:ahbottomnavigation:1.5.1'
52+
implementation project(':cropper')
53+
implementation project(':onboarder')
5554
}

app/src/androidTest/java/io/github/scola/qart/ApplicationTest.java

-13
This file was deleted.

app/src/main/java/io/github/scola/gif/AnimatedGifEncoder.java

+7-7
Original file line numberDiff line numberDiff line change
@@ -547,11 +547,11 @@ class NeuQuant {
547547
/* defs for freq and bias */
548548
protected static final int intbiasshift = 16; /* bias for fractions */
549549

550-
protected static final int intbias = (((int) 1) << intbiasshift);
550+
protected static final int intbias = (1 << intbiasshift);
551551

552552
protected static final int gammashift = 10; /* gamma = 1024 */
553553

554-
protected static final int gamma = (((int) 1) << gammashift);
554+
protected static final int gamma = (1 << gammashift);
555555

556556
protected static final int betashift = 10;
557557

@@ -567,7 +567,7 @@ class NeuQuant {
567567

568568
protected static final int radiusbiasshift = 6; /* at 32.0 biased by 6 bits */
569569

570-
protected static final int radiusbias = (((int) 1) << radiusbiasshift);
570+
protected static final int radiusbias = (1 << radiusbiasshift);
571571

572572
protected static final int initradius = (initrad * radiusbias); /*
573573
* and
@@ -580,18 +580,18 @@ class NeuQuant {
580580
/* defs for decreasing alpha factor */
581581
protected static final int alphabiasshift = 10; /* alpha starts at 1.0 */
582582

583-
protected static final int initalpha = (((int) 1) << alphabiasshift);
583+
protected static final int initalpha = (1 << alphabiasshift);
584584

585585
protected int alphadec; /* biased by 10 bits */
586586

587587
/* radbias and alpharadbias used for radpower calculation */
588588
protected static final int radbiasshift = 8;
589589

590-
protected static final int radbias = (((int) 1) << radbiasshift);
590+
protected static final int radbias = (1 << radbiasshift);
591591

592592
protected static final int alpharadbshift = (alphabiasshift + radbiasshift);
593593

594-
protected static final int alpharadbias = (((int) 1) << alpharadbshift);
594+
protected static final int alpharadbias = (1 << alpharadbshift);
595595

596596
/*
597597
* Types and Global Variables --------------------------
@@ -954,7 +954,7 @@ protected int contest(int b, int g, int r) {
954954
int bestpos, bestbiaspos, bestd, bestbiasd;
955955
int[] n;
956956

957-
bestd = ~(((int) 1) << 31);
957+
bestd = ~(1 << 31);
958958
bestbiasd = bestd;
959959
bestpos = -1;
960960
bestbiaspos = bestpos;

0 commit comments

Comments
 (0)