Check kotlin format before uploading

This uses ktfmt on the PREUPLOAD hook to check file formatting.

Bug: 264851618
Test: manual
Change-Id: I8bdeabd9c1ed571a464707e6912419ad3190a169
Merged-In: I8bdeabd9c1ed571a464707e6912419ad3190a169
diff --git a/src/com/android/launcher3/LauncherPrefs.kt b/src/com/android/launcher3/LauncherPrefs.kt
index 23ff10a..0d6ed04 100644
--- a/src/com/android/launcher3/LauncherPrefs.kt
+++ b/src/com/android/launcher3/LauncherPrefs.kt
@@ -9,12 +9,17 @@
     fun getPrefs(context: Context): SharedPreferences {
         // Use application context for shared preferences, so that we use a single cached instance
         return context.applicationContext.getSharedPreferences(
-                LauncherFiles.SHARED_PREFERENCES_KEY, Context.MODE_PRIVATE)
+            LauncherFiles.SHARED_PREFERENCES_KEY,
+            Context.MODE_PRIVATE
+        )
     }
 
     @JvmStatic
     fun getDevicePrefs(context: Context): SharedPreferences {
         // Use application context for shared preferences, so that we use a single cached instance
         return context.applicationContext.getSharedPreferences(
-                LauncherFiles.DEVICE_PREFERENCES_KEY, Context.MODE_PRIVATE)
-    }}
\ No newline at end of file
+            LauncherFiles.DEVICE_PREFERENCES_KEY,
+            Context.MODE_PRIVATE
+        )
+    }
+}
diff --git a/src/com/android/launcher3/util/DimensionUtils.kt b/src/com/android/launcher3/util/DimensionUtils.kt
index 758b3a9..1922310 100644
--- a/src/com/android/launcher3/util/DimensionUtils.kt
+++ b/src/com/android/launcher3/util/DimensionUtils.kt
@@ -24,12 +24,15 @@
 
 object DimensionUtils {
     /**
-     * Point where x is width, and y is height of taskbar based on provided [deviceProfile]
-     * x or y could also be -1 to indicate there is no dimension specified
+     * Point where x is width, and y is height of taskbar based on provided [deviceProfile] x or y
+     * could also be -1 to indicate there is no dimension specified
      */
     @JvmStatic
-    fun getTaskbarPhoneDimensions(deviceProfile: DeviceProfile, res: Resources,
-                                  isPhoneMode: Boolean): Point {
+    fun getTaskbarPhoneDimensions(
+        deviceProfile: DeviceProfile,
+        res: Resources,
+        isPhoneMode: Boolean
+    ): Point {
         val p = Point()
         // Taskbar for large screen
         if (!isPhoneMode) {
@@ -57,4 +60,4 @@
         p.y = ViewGroup.LayoutParams.MATCH_PARENT
         return p
     }
-}
\ No newline at end of file
+}