remove some unnecessary brackets

This commit is contained in:
tibbi 2017-01-02 19:49:04 +01:00
parent e713452b30
commit 65c8658151
8 changed files with 21 additions and 41 deletions

View file

@ -37,7 +37,7 @@
<ConfirmationsSetting value="0" id="Add" />
<ConfirmationsSetting value="0" id="Remove" />
</component>
<component name="ProjectRootManager" version="2" languageLevel="JDK_1_8" default="true" assert-keyword="true" jdk-15="true" project-jdk-name="1.8" project-jdk-type="JavaSDK">
<component name="ProjectRootManager" version="2" languageLevel="JDK_1_7" default="true" assert-keyword="true" jdk-15="true" project-jdk-name="1.8" project-jdk-type="JavaSDK">
<output url="file://$PROJECT_DIR$/build/classes" />
</component>
<component name="ProjectType">

View file

@ -7,14 +7,11 @@ import android.util.AttributeSet
import com.simplemobiletools.commons.R
class MyAppCompatCheckbox : AppCompatCheckBox {
constructor(context: Context) : super(context) {
}
constructor(context: Context) : super(context)
constructor(context: Context, attrs: AttributeSet) : super(context, attrs) {
}
constructor(context: Context, attrs: AttributeSet) : super(context, attrs)
constructor(context: Context, attrs: AttributeSet, defStyle: Int) : super(context, attrs, defStyle) {
}
constructor(context: Context, attrs: AttributeSet, defStyle: Int) : super(context, attrs, defStyle)
fun setColors(textColor: Int, accentColor: Int, backgroundColor: Int) {
setTextColor(textColor)

View file

@ -11,14 +11,11 @@ import com.simplemobiletools.commons.R
import com.simplemobiletools.commons.adapters.MyArrayAdapter
class MyAppCompatSpinner : AppCompatSpinner {
constructor(context: Context) : super(context) {
}
constructor(context: Context) : super(context)
constructor(context: Context, attrs: AttributeSet) : super(context, attrs) {
}
constructor(context: Context, attrs: AttributeSet) : super(context, attrs)
constructor(context: Context, attrs: AttributeSet, defStyle: Int) : super(context, attrs, defStyle) {
}
constructor(context: Context, attrs: AttributeSet, defStyle: Int) : super(context, attrs, defStyle)
fun setColors(textColor: Int, accentColor: Int, backgroundColor: Int) {
val cnt = adapter.count

View file

@ -7,14 +7,11 @@ import android.util.AttributeSet
import com.simplemobiletools.commons.R
class MyCompatRadioButton : AppCompatRadioButton {
constructor(context: Context) : super(context) {
}
constructor(context: Context) : super(context)
constructor(context: Context, attrs: AttributeSet) : super(context, attrs) {
}
constructor(context: Context, attrs: AttributeSet) : super(context, attrs)
constructor(context: Context, attrs: AttributeSet, defStyle: Int) : super(context, attrs, defStyle) {
}
constructor(context: Context, attrs: AttributeSet, defStyle: Int) : super(context, attrs, defStyle)
fun setColors(textColor: Int, accentColor: Int, backgroundColor: Int) {
setTextColor(textColor)

View file

@ -6,14 +6,11 @@ import android.util.AttributeSet
import android.widget.EditText
class MyEditText : EditText {
constructor(context: Context) : super(context) {
}
constructor(context: Context) : super(context)
constructor(context: Context, attrs: AttributeSet) : super(context, attrs) {
}
constructor(context: Context, attrs: AttributeSet) : super(context, attrs)
constructor(context: Context, attrs: AttributeSet, defStyle: Int) : super(context, attrs, defStyle) {
}
constructor(context: Context, attrs: AttributeSet, defStyle: Int) : super(context, attrs, defStyle)
fun setColors(textColor: Int, accentColor: Int, backgroundColor: Int) {
background.mutate().setColorFilter(accentColor, PorterDuff.Mode.SRC_ATOP)

View file

@ -9,14 +9,11 @@ import com.simplemobiletools.commons.R
import com.simplemobiletools.commons.extensions.adjustAlpha
class MySwitchCompat : SwitchCompat {
constructor(context: Context) : super(context) {
}
constructor(context: Context) : super(context)
constructor(context: Context, attrs: AttributeSet) : super(context, attrs) {
}
constructor(context: Context, attrs: AttributeSet) : super(context, attrs)
constructor(context: Context, attrs: AttributeSet, defStyle: Int) : super(context, attrs, defStyle) {
}
constructor(context: Context, attrs: AttributeSet, defStyle: Int) : super(context, attrs, defStyle)
fun setColors(textColor: Int, accentColor: Int, backgroundColor: Int) {
setTextColor(textColor)

View file

@ -5,14 +5,11 @@ import android.util.AttributeSet
import android.widget.TextView
class MyTextView : TextView {
constructor(context: Context) : super(context) {
}
constructor(context: Context) : super(context)
constructor(context: Context, attrs: AttributeSet) : super(context, attrs) {
}
constructor(context: Context, attrs: AttributeSet) : super(context, attrs)
constructor(context: Context, attrs: AttributeSet, defStyle: Int) : super(context, attrs, defStyle) {
}
constructor(context: Context, attrs: AttributeSet, defStyle: Int) : super(context, attrs, defStyle)
fun setColors(textColor: Int, accentColor: Int, backgroundColor: Int) {
setTextColor(textColor)

View file

@ -8,11 +8,9 @@ import com.booking.rtlviewpager.RtlViewPager
class MyViewPager : RtlViewPager {
constructor(context: Context) : super(context) {
}
constructor(context: Context) : super(context)
constructor(context: Context, attrs: AttributeSet) : super(context, attrs) {
}
constructor(context: Context, attrs: AttributeSet) : super(context, attrs)
override fun onInterceptTouchEvent(ev: MotionEvent): Boolean {
try {