Auto reformat the entire codebase

This commit is contained in:
Lonami Exo 2019-09-05 16:48:14 +02:00
parent 5e5cfc3d5f
commit c61b4827c1
10 changed files with 136 additions and 134 deletions

View file

@ -41,12 +41,12 @@ task copyAndroidNatives() {
configurations.natives.files.each { jar -> configurations.natives.files.each { jar ->
def outputDir = null def outputDir = null
if(jar.name.endsWith("natives-arm64-v8a.jar")) outputDir = file("libs/arm64-v8a") if (jar.name.endsWith("natives-arm64-v8a.jar")) outputDir = file("libs/arm64-v8a")
if(jar.name.endsWith("natives-armeabi-v7a.jar")) outputDir = file("libs/armeabi-v7a") if (jar.name.endsWith("natives-armeabi-v7a.jar")) outputDir = file("libs/armeabi-v7a")
if(jar.name.endsWith("natives-armeabi.jar")) outputDir = file("libs/armeabi") if (jar.name.endsWith("natives-armeabi.jar")) outputDir = file("libs/armeabi")
if(jar.name.endsWith("natives-x86_64.jar")) outputDir = file("libs/x86_64") if (jar.name.endsWith("natives-x86_64.jar")) outputDir = file("libs/x86_64")
if(jar.name.endsWith("natives-x86.jar")) outputDir = file("libs/x86") if (jar.name.endsWith("natives-x86.jar")) outputDir = file("libs/x86")
if(outputDir != null) { if (outputDir != null) {
copy { copy {
from zipTree(jar) from zipTree(jar)
into outputDir into outputDir
@ -94,7 +94,7 @@ eclipse {
} }
classpath { classpath {
plusConfigurations += [ project.configurations.compile ] plusConfigurations += [project.configurations.compile]
containers 'com.android.ide.eclipse.adt.ANDROID_FRAMEWORK', 'com.android.ide.eclipse.adt.LIBRARIES' containers 'com.android.ide.eclipse.adt.ANDROID_FRAMEWORK', 'com.android.ide.eclipse.adt.LIBRARIES'
} }
@ -113,7 +113,7 @@ eclipse {
idea { idea {
module { module {
sourceDirs += file("src") sourceDirs += file("src")
scopes = [ COMPILE: [plus:[project.configurations.compile]]] scopes = [COMPILE: [plus: [project.configurations.compile]]]
iml { iml {
withXml { withXml {
@ -123,7 +123,7 @@ idea {
builder.component(name: "FacetManager") { builder.component(name: "FacetManager") {
facet(type: "android", name: "Android") { facet(type: "android", name: "Android") {
configuration { configuration {
option(name: "UPDATE_PROPERTY_FILES", value:"true") option(name: "UPDATE_PROPERTY_FILES", value: "true")
} }
} }
} }

View file

@ -24,7 +24,7 @@ import com.badlogic.gdx.backends.android.AndroidApplicationConfiguration;
public class AndroidLauncher extends AndroidApplication { public class AndroidLauncher extends AndroidApplication {
@Override @Override
protected void onCreate (Bundle savedInstanceState) { protected void onCreate(Bundle savedInstanceState) {
super.onCreate(savedInstanceState); super.onCreate(savedInstanceState);
final AndroidApplicationConfiguration config = new AndroidApplicationConfiguration(); final AndroidApplicationConfiguration config = new AndroidApplicationConfiguration();
final AndroidShareChallenge shareChallenge = new AndroidShareChallenge(this); final AndroidShareChallenge shareChallenge = new AndroidShareChallenge(this);

View file

@ -3,7 +3,7 @@ apply plugin: "java"
sourceCompatibility = 1.6 sourceCompatibility = 1.6
[compileJava, compileTestJava]*.options*.encoding = 'UTF-8' [compileJava, compileTestJava]*.options*.encoding = 'UTF-8'
sourceSets.main.java.srcDirs = [ "src/" ] sourceSets.main.java.srcDirs = ["src/"]
eclipse.project { eclipse.project {

View file

@ -1,5 +1,6 @@
<?xml version="1.0" encoding="UTF-8"?> <?xml version="1.0" encoding="UTF-8"?><!DOCTYPE module PUBLIC
<!DOCTYPE module PUBLIC "-//Google Inc.//DTD Google Web Toolkit trunk//EN" "http://google-web-toolkit.googlecode.com/svn/trunk/distro-source/core/src/gwt-module.dtd"> "-//Google Inc.//DTD Google Web Toolkit trunk//EN"
"http://google-web-toolkit.googlecode.com/svn/trunk/distro-source/core/src/gwt-module.dtd">
<module> <module>
<source path="io/github/lonamiwebs/klooni" /> <source path="io/github/lonamiwebs/klooni" />
</module> </module>

View file

@ -1,7 +1,7 @@
apply plugin: "java" apply plugin: "java"
sourceCompatibility = 1.6 sourceCompatibility = 1.6
sourceSets.main.java.srcDirs = [ "src/" ] sourceSets.main.java.srcDirs = ["src/"]
project.ext.mainClassName = "dev.lonami.klooni.desktop.DesktopLauncher" project.ext.mainClassName = "dev.lonami.klooni.desktop.DesktopLauncher"
project.ext.assetsDir = new File("../android/assets") project.ext.assetsDir = new File("../android/assets")
@ -17,7 +17,7 @@ task run(dependsOn: classes, type: JavaExec) {
task dist(type: Jar) { task dist(type: Jar) {
from files(sourceSets.main.output.classesDirs) from files(sourceSets.main.output.classesDirs)
from files(sourceSets.main.output.resourcesDir) from files(sourceSets.main.output.resourcesDir)
from {configurations.compile.collect {zipTree(it)}} from { configurations.compile.collect { zipTree(it) } }
from files(project.assetsDir) from files(project.assetsDir)
manifest { manifest {

View file

@ -20,10 +20,11 @@ package dev.lonami.klooni.desktop;
import com.badlogic.gdx.Files; import com.badlogic.gdx.Files;
import com.badlogic.gdx.backends.lwjgl.LwjglApplication; import com.badlogic.gdx.backends.lwjgl.LwjglApplication;
import com.badlogic.gdx.backends.lwjgl.LwjglApplicationConfiguration; import com.badlogic.gdx.backends.lwjgl.LwjglApplicationConfiguration;
import dev.lonami.klooni.Klooni; import dev.lonami.klooni.Klooni;
class DesktopLauncher { class DesktopLauncher {
public static void main (String[] arg) { public static void main(String[] arg) {
LwjglApplicationConfiguration config = new LwjglApplicationConfiguration(); LwjglApplicationConfiguration config = new LwjglApplicationConfiguration();
config.title = "Klooni 1010!"; config.title = "Klooni 1010!";
config.width = Klooni.GAME_WIDTH; config.width = Klooni.GAME_WIDTH;

View file

@ -1,7 +1,7 @@
<?xml version="1.0" encoding="UTF-8"?> <?xml version="1.0" encoding="UTF-8"?><!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN"
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd"> "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0"> <plist version="1.0">
<dict> <dict>
<key>CFBundleDevelopmentRegion</key> <key>CFBundleDevelopmentRegion</key>
<string>en</string> <string>en</string>
<key>CFBundleDisplayName</key> <key>CFBundleDisplayName</key>
@ -23,11 +23,11 @@
<key>CFBundleVersion</key> <key>CFBundleVersion</key>
<string>${app.build}</string> <string>${app.build}</string>
<key>LSRequiresIPhoneOS</key> <key>LSRequiresIPhoneOS</key>
<true/> <true />
<key>UIViewControllerBasedStatusBarAppearance</key> <key>UIViewControllerBasedStatusBarAppearance</key>
<false/> <false />
<key>UIStatusBarHidden</key> <key>UIStatusBarHidden</key>
<true/> <true />
<key>UIDeviceFamily</key> <key>UIDeviceFamily</key>
<array> <array>
<integer>1</integer> <integer>1</integer>
@ -55,5 +55,5 @@
</array> </array>
</dict> </dict>
</dict> </dict>
</dict> </dict>
</plist> </plist>

View file

@ -1,4 +1,4 @@
sourceSets.main.java.srcDirs = [ "src/" ] sourceSets.main.java.srcDirs = ["src/"]
sourceCompatibility = '1.7' sourceCompatibility = '1.7'
[compileJava, compileTestJava]*.options*.encoding = 'UTF-8' [compileJava, compileTestJava]*.options*.encoding = 'UTF-8'

View file

@ -26,7 +26,8 @@
<pattern>com.android.org.bouncycastle.jce.provider.BouncyCastleProvider</pattern> <pattern>com.android.org.bouncycastle.jce.provider.BouncyCastleProvider</pattern>
<pattern>com.android.org.bouncycastle.jcajce.provider.keystore.BC$Mappings</pattern> <pattern>com.android.org.bouncycastle.jcajce.provider.keystore.BC$Mappings</pattern>
<pattern>com.android.org.bouncycastle.jcajce.provider.keystore.bc.BcKeyStoreSpi</pattern> <pattern>com.android.org.bouncycastle.jcajce.provider.keystore.bc.BcKeyStoreSpi</pattern>
<pattern>com.android.org.bouncycastle.jcajce.provider.keystore.bc.BcKeyStoreSpi$Std</pattern> <pattern>com.android.org.bouncycastle.jcajce.provider.keystore.bc.BcKeyStoreSpi$Std
</pattern>
<pattern>com.android.org.bouncycastle.jce.provider.PKIXCertPathValidatorSpi</pattern> <pattern>com.android.org.bouncycastle.jce.provider.PKIXCertPathValidatorSpi</pattern>
<pattern>com.android.org.bouncycastle.crypto.digests.AndroidDigestFactoryOpenSSL</pattern> <pattern>com.android.org.bouncycastle.crypto.digests.AndroidDigestFactoryOpenSSL</pattern>
<pattern>org.apache.harmony.security.provider.cert.DRLCertFactory</pattern> <pattern>org.apache.harmony.security.provider.cert.DRLCertFactory</pattern>

View file

@ -17,12 +17,11 @@
*/ */
package dev.lonami.klooni; package dev.lonami.klooni;
import org.robovm.apple.foundation.NSAutoreleasePool;
import org.robovm.apple.uikit.UIApplication;
import com.badlogic.gdx.backends.iosrobovm.IOSApplication; import com.badlogic.gdx.backends.iosrobovm.IOSApplication;
import com.badlogic.gdx.backends.iosrobovm.IOSApplicationConfiguration; import com.badlogic.gdx.backends.iosrobovm.IOSApplicationConfiguration;
import dev.lonami.klooni.Klooni;
import org.robovm.apple.foundation.NSAutoreleasePool;
import org.robovm.apple.uikit.UIApplication;
class IOSLauncher extends IOSApplication.Delegate { class IOSLauncher extends IOSApplication.Delegate {
@Override @Override