General impovements of the ScientificActivity

This commit is contained in:
Sissy Dalampira 2018-10-07 21:04:40 +03:00
parent c9a41c22fb
commit ce425b3087
4 changed files with 6 additions and 17 deletions

View File

@ -34,7 +34,6 @@ class MainActivity : SimpleActivity(), Calculator {
calc = CalculatorImpl(this, applicationContext)
btn_factorial.setOnClickListener{ calc.handleOperation(FACTORIAL); checkHaptic(it) }
btn_plus.setOnClickListener { calc.handleOperation(PLUS); checkHaptic(it) }
btn_minus.setOnClickListener { calc.handleOperation(MINUS); checkHaptic(it) }
btn_multiply.setOnClickListener { calc.handleOperation(MULTIPLY); checkHaptic(it) }

View File

@ -4,20 +4,18 @@ import android.os.Bundle
import com.simplemobiletools.calculator.R
import com.simplemobiletools.calculator.extensions.config
import com.simplemobiletools.calculator.extensions.updateViewColors
import com.simplemobiletools.calculator.helpers.*
import kotlinx.android.synthetic.main.activity_main.*
import com.simplemobiletools.calculator.BuildConfig
import com.simplemobiletools.commons.extensions.*
class ScientificActivity : SimpleActivity() {
// lateinit var calc: CalculatorImpl
override fun onCreate(savedInstanceState: Bundle?) {
super.onCreate(savedInstanceState)
setContentView(R.layout.scientific_activity)
//appLaunched(BuildConfig.APPLICATION_ID)
appLaunched(BuildConfig.APPLICATION_ID)
// calc = CalculatorImpl(this, applicationContext)
updateViewColors(calculator_holder, config.textColor)
}

View File

@ -40,14 +40,6 @@
android:layout_weight="2"
android:orientation="horizontal">
<Button
android:id="@+id/btn_factorial"
style="@style/MyButton"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:layout_weight="1"
android:text="!"/>
<Button
android:id="@+id/btn_percent"
style="@style/MyButton"

View File

@ -32,7 +32,7 @@
android:paddingLeft="@dimen/activity_margin"
android:paddingRight="@dimen/activity_margin"
android:textSize="@dimen/display_text_size"
tools:text="0"/>
android:text="0"/>
<LinearLayout
android:layout_width="match_parent"