Skip to content

Commit

Permalink
[ gradle ] Bug fix.
Browse files Browse the repository at this point in the history
  • Loading branch information
ice1000 committed Dec 19, 2017
1 parent 66d92eb commit 8488918
Show file tree
Hide file tree
Showing 12 changed files with 4 additions and 325 deletions.
6 changes: 0 additions & 6 deletions build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -6,12 +6,6 @@ buildscript {
repositories {
mavenCentral()
jcenter()
// maven {
// url "http://repository.jetbrains.com/all"
// }
// dependencies {
// classpath "org.jetbrains.kotlin:kotlin-gradle-plugin:$kotlin_version"
// }
}
dependencies {
classpath 'com.android.tools.build:gradle:2.3.1'
Expand Down
1 change: 1 addition & 0 deletions frice/build.gradle
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
apply plugin: 'com.android.library'
apply plugin: 'com.github.dcendents.android-maven'
apply plugin: 'kotlin-android'

group 'com.github.ice1000'

Expand Down
28 changes: 0 additions & 28 deletions frice/src/main/kotlin/org/frice/obj/effects/Effects.kt
Original file line number Diff line number Diff line change
@@ -1,12 +1,8 @@
package org.frice.obj.effects

import org.frice.obj.AbstractObject
import org.frice.obj.sub.ImageObject
import org.frice.platform.FriceImage
import org.frice.resource.graphics.ColorResource
import org.frice.resource.graphics.ColorResource.Companion.BLACK
import org.frice.resource.graphics.ParticleResource
import org.frice.resource.image.ImageResource

/**
* Created by ice1000 on 2016/8/19.
Expand All @@ -25,27 +21,3 @@ constructor(

override var rotate = 0.0
}

/**
* Created by ice1000 on 2016/8/17.
* @author ice1000
* @since 0.3.2
*/
class ParticleEffect(
private var pRes: ParticleResource,
override var x: Double,
override var y: Double) : ImageObject(pRes.resource, x, y) {
override val image: FriceImage get() = pRes.resource

override val width: Double get() = pRes.width.toDouble()
override val height: Double get() = pRes.height.toDouble()

override val resource: ImageResource get() = ImageResource(image)

override fun scale(x: Double, y: Double) {
pRes.width = (pRes.width * x / 1000.0).toInt()
pRes.height = (pRes.height * y / 1000.0).toInt()
}

// override fun collides(other: Collidable): Boolean = false
}
45 changes: 0 additions & 45 deletions frice/src/main/kotlin/org/frice/platform/adapter/JvmImage.kt

This file was deleted.

This file was deleted.

7 changes: 2 additions & 5 deletions frice/src/main/kotlin/org/frice/utils/FileUtils.kt
Original file line number Diff line number Diff line change
Expand Up @@ -13,16 +13,13 @@ import org.frice.platform.adapter.DroidImage
import org.frice.resource.manager.*
import java.io.File

fun Bitmap.image2File(type: String, file: File) = DroidImage(image = this).image2File(type, file)
fun Bitmap.image2File(file: File) = DroidImage(image = this).image2File(file)

fun DroidImage.image2File(type: String, file: File) {
fun DroidImage.image2File(file: File) {
image.compress(Bitmap.CompressFormat.PNG, 85, file.outputStream())
ImageManager[file.absolutePath] = this
}

fun Bitmap.image2File(file: File) = image2File("png", file)
fun DroidImage.image2File(file: File) = image2File("png", file)

fun Bitmap.image2File(file: String) = image2File(File(file))
fun DroidImage.image2File(file: String) = image2File(File(file))

Expand Down
41 changes: 0 additions & 41 deletions frice/src/main/kotlin/org/frice/utils/media/AudioManager.kt

This file was deleted.

50 changes: 0 additions & 50 deletions frice/src/main/kotlin/org/frice/utils/media/AudioPlayer.kt

This file was deleted.

32 changes: 0 additions & 32 deletions frice/src/main/kotlin/org/frice/utils/media/LoopAudioPlayer.kt

This file was deleted.

21 changes: 0 additions & 21 deletions frice/src/main/kotlin/org/frice/utils/media/MediaManager.kt

This file was deleted.

24 changes: 0 additions & 24 deletions frice/src/main/kotlin/org/frice/utils/media/OnceAudioPlayer.kt

This file was deleted.

3 changes: 1 addition & 2 deletions frice/src/main/kotlin/org/frice/utils/shape/Shapes.kt
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
package org.frice.utils.shape

import java.awt.geom.Rectangle2D
import android.graphics.RectF

interface FShapeInt {
var width: Int
Expand Down Expand Up @@ -40,7 +40,6 @@ data class FPoint(var x: Int, var y: Int)
* @since v0.1.1
*/
open class FRectangle(override var width: Int, override var height: Int) : FShapeInt {
constructor(rect: Rectangle2D) : this(rect.width.toInt(), rect.height.toInt())
constructor(width: Double, height: Double) : this(width.toInt(), height.toInt())
constructor(width: Float, height: Float) : this(width.toInt(), height.toInt())
}
Expand Down

0 comments on commit 8488918

Please sign in to comment.