Skip to content

Commit 894d10f

Browse files
authored
Add files via upload
1 parent 6c30ca2 commit 894d10f

28 files changed

+1524
-1
lines changed

AndroidManifest.xml

Lines changed: 27 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,27 @@
1+
<?xml version="1.0" encoding="utf-8"?>
2+
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
3+
package="com.kasroudra.kascalc"
4+
android:versionCode="1"
5+
android:versionName="1.0" >
6+
7+
<uses-sdk
8+
android:minSdkVersion="8"
9+
android:targetSdkVersion="17" />
10+
11+
<application
12+
android:allowBackup="true"
13+
android:icon="@mipmap/ic_launcher"
14+
android:label="@string/app_name"
15+
android:theme="@style/AppTheme" >
16+
<activity
17+
android:name=".Calculator"
18+
android:label="@string/app_name" >
19+
<intent-filter>
20+
<action android:name="android.intent.action.MAIN" />
21+
22+
<category android:name="android.intent.category.LAUNCHER" />
23+
</intent-filter>
24+
</activity>
25+
</application>
26+
27+
</manifest>

README.md

Lines changed: 22 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1,22 @@
1-
# simplecalculator
1+
# Simple Android Calculator
2+
3+
### Features
4+
5+
1. Addition, Multiplication, Substraction, Division, Percentage, Logarithm, Exponential, Root, Sin, Cos, Tan, Root.
6+
2. About menu for toast text (Appears for 2 seconds in bottom).
7+
3. Round buttons with ripple effects.
8+
4. Close Menu for exit.
9+
10+
## Screenshots:
11+
12+
#### My app:
13+
14+
<img src="https://github.com/KasRoudra/simplecalculator/raw/main/my.jpeg">
15+
16+
#### Source app:
17+
18+
<img src="https://github.com/KasRoudra/simplecalculator/raw/main/source.jpeg">
19+
20+
### Source Code credit <a href="https://github.com/CMDann/Simple-Android-Calculator">CMDann</a>
21+
22+
#### Developed for learning purposes. New java learners can easlily understand how calculator works by this small and simple app.

app.project

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
NAME= KasCalc

ic_launcher.png

17.9 KB
Loading

libs/android-support-v4.jar

377 KB
Binary file not shown.

my.jpeg

338 KB
Loading

proguard-project.txt

Lines changed: 20 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,20 @@
1+
# To enable ProGuard in your project, edit project.properties
2+
# to define the proguard.config property as described in that file.
3+
#
4+
# Add project specific ProGuard rules here.
5+
# By default, the flags in this file are appended to flags specified
6+
# in ${sdk.dir}/tools/proguard/proguard-android.txt
7+
# You can edit the include path and order by changing the ProGuard
8+
# include property in project.properties.
9+
#
10+
# For more details, see
11+
# http://developer.android.com/guide/developing/tools/proguard.html
12+
13+
# Add any project specific keep options here:
14+
15+
# If your project uses WebView with JS, uncomment the following
16+
# and specify the fully qualified class name to the JavaScript interface
17+
# class:
18+
#-keepclassmembers class fqcn.of.javascript.interface.for.webview {
19+
# public *;
20+
#}

project.properties

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,14 @@
1+
# This file is automatically generated by Android Tools.
2+
# Do not modify this file -- YOUR CHANGES WILL BE ERASED!
3+
#
4+
# This file must be checked in Version Control Systems.
5+
#
6+
# To customize properties used by the Ant build system edit
7+
# "ant.properties", and override values to adapt the script to your
8+
# project structure.
9+
#
10+
# To enable ProGuard to shrink and obfuscate your code, uncomment this (available properties: sdk.dir, user.home):
11+
#proguard.config=${sdk.dir}/tools/proguard/proguard-android.txt:proguard-project.txt
12+
13+
# Project target.
14+
target=android-17

res/drawable/custombutton.xml

Lines changed: 60 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,60 @@
1+
<?xml version="1.0" encoding="utf-8"?>
2+
<selector xmlns:android="http://schemas.android.com/apk/res/android">
3+
<item android:state_pressed="true" >
4+
<shape>
5+
<gradient
6+
android:startColor="@color/black42"
7+
android:endColor="@color/black42"
8+
android:angle="270" />
9+
<stroke
10+
android:width="3dp"
11+
android:color="@color/white1" />
12+
<corners
13+
android:radius="3dp" />
14+
<padding
15+
android:left="10dp"
16+
android:top="10dp"
17+
android:right="10dp"
18+
android:bottom="10dp" />
19+
</shape>
20+
</item>
21+
22+
<item android:state_focused="true" >
23+
<shape>
24+
<gradient
25+
android:endColor="@color/drkgray3"
26+
android:startColor="@color/drkgray5"
27+
android:angle="270" />
28+
<stroke
29+
android:width="3dp"
30+
android:color="@color/black42" />
31+
<corners
32+
android:radius="3dp" />
33+
<padding
34+
android:left="10dp"
35+
android:top="10dp"
36+
android:right="10dp"
37+
android:bottom="10dp" />
38+
</shape>
39+
</item>
40+
41+
<item>
42+
<shape android:shape="oval">
43+
<gradient
44+
android:endColor="@color/drkgray3"
45+
android:startColor="@color/drkgray5"
46+
android:angle="270" />
47+
<stroke
48+
android:width="3dp"
49+
android:color="@color/black42" />
50+
<corners
51+
android:radius="3dp" />
52+
<padding
53+
android:left="10dp"
54+
android:top="10dp"
55+
android:right="10dp"
56+
android:bottom="10dp" />
57+
</shape>
58+
</item>
59+
60+
</selector>

res/drawable/custombutton2.xml

Lines changed: 60 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,60 @@
1+
<?xml version="1.0" encoding="utf-8"?>
2+
<selector xmlns:android="http://schemas.android.com/apk/res/android">
3+
<item android:state_pressed="true" >
4+
<shape>
5+
<gradient
6+
android:startColor="@color/black42"
7+
android:endColor="@color/black42"
8+
android:angle="270" />
9+
<stroke
10+
android:width="3dp"
11+
android:color="@color/white1" />
12+
<corners
13+
android:radius="3dp" />
14+
<padding
15+
android:left="10dp"
16+
android:top="10dp"
17+
android:right="10dp"
18+
android:bottom="10dp" />
19+
</shape>
20+
</item>
21+
22+
<item android:state_focused="true" >
23+
<shape>
24+
<gradient
25+
android:endColor="@color/drkgray35"
26+
android:startColor="@color/drkgray36"
27+
android:angle="270" />
28+
<stroke
29+
android:width="3dp"
30+
android:color="@color/black42" />
31+
<corners
32+
android:radius="3dp" />
33+
<padding
34+
android:left="10dp"
35+
android:top="10dp"
36+
android:right="10dp"
37+
android:bottom="10dp" />
38+
</shape>
39+
</item>
40+
41+
<item>
42+
<shape>
43+
<gradient
44+
android:endColor="@color/drkgray35"
45+
android:startColor="@color/drkgray36"
46+
android:angle="270" />
47+
<stroke
48+
android:width="3dp"
49+
android:color="@color/black42" />
50+
<corners
51+
android:radius="3dp" />
52+
<padding
53+
android:left="10dp"
54+
android:top="10dp"
55+
android:right="10dp"
56+
android:bottom="10dp" />
57+
</shape>
58+
</item>
59+
60+
</selector>

res/drawable/custombutton3.xml

Lines changed: 60 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,60 @@
1+
<?xml version="1.0" encoding="utf-8"?>
2+
<selector xmlns:android="http://schemas.android.com/apk/res/android">
3+
<item android:state_pressed="true" >
4+
<shape>
5+
<gradient
6+
android:startColor="@color/black42"
7+
android:endColor="@color/black42"
8+
android:angle="270" />
9+
<stroke
10+
android:width="3dp"
11+
android:color="@color/white1" />
12+
<corners
13+
android:radius="3dp" />
14+
<padding
15+
android:left="10dp"
16+
android:top="10dp"
17+
android:right="10dp"
18+
android:bottom="10dp" />
19+
</shape>
20+
</item>
21+
22+
<item android:state_focused="true" >
23+
<shape>
24+
<gradient
25+
android:endColor="@color/drkred35"
26+
android:startColor="@color/drkred36"
27+
android:angle="270" />
28+
<stroke
29+
android:width="3dp"
30+
android:color="@color/black42" />
31+
<corners
32+
android:radius="3dp" />
33+
<padding
34+
android:left="10dp"
35+
android:top="10dp"
36+
android:right="10dp"
37+
android:bottom="10dp" />
38+
</shape>
39+
</item>
40+
41+
<item>
42+
<shape>
43+
<gradient
44+
android:endColor="@color/drkred35"
45+
android:startColor="@color/drkred36"
46+
android:angle="270" />
47+
<stroke
48+
android:width="3dp"
49+
android:color="@color/black42" />
50+
<corners
51+
android:radius="3dp" />
52+
<padding
53+
android:left="10dp"
54+
android:top="10dp"
55+
android:right="10dp"
56+
android:bottom="10dp" />
57+
</shape>
58+
</item>
59+
60+
</selector>

res/drawable/redbutton.xml

Lines changed: 19 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,19 @@
1+
<?xml version="1.0" encoding="utf-8"?>
2+
<ripple xmlns:android="http://schemas.android.com/apk/res/android"
3+
android:color="#F8A313DC">
4+
<item android:id="@android:id/mask">
5+
<shape android:shape="oval">
6+
<solid android:color="#F8D925B1" />
7+
</shape>
8+
</item>
9+
10+
<item android:id="@android:id/background">
11+
<shape android:shape="oval">
12+
<gradient
13+
android:angle="90"
14+
android:endColor="#F8EB5EAE"
15+
android:startColor="#F8F90774"
16+
android:type="linear" />
17+
</shape>
18+
</item>
19+
</ripple>

res/drawable/roundbutton.xml

Lines changed: 19 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,19 @@
1+
<?xml version="1.0" encoding="utf-8"?>
2+
<ripple xmlns:android="http://schemas.android.com/apk/res/android"
3+
android:color="#F8DF3FBC">
4+
<item android:id="@android:id/mask">
5+
<shape android:shape="oval">
6+
<solid android:color="#F8F08BDA" />
7+
</shape>
8+
</item>
9+
10+
<item android:id="@android:id/background">
11+
<shape android:shape="oval">
12+
<gradient
13+
android:angle="90"
14+
android:endColor="#F8EEDF7E"
15+
android:startColor="#F8EE7EC5"
16+
android:type="linear" />
17+
</shape>
18+
</item>
19+
</ripple>

res/layout/activity_calculator.xml

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,14 @@
1+
<RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android"
2+
xmlns:tools="http://schemas.android.com/tools"
3+
android:layout_width="match_parent"
4+
android:layout_height="match_parent"
5+
tools:context=".Calculator" >
6+
7+
<TextView
8+
android:layout_width="wrap_content"
9+
android:layout_height="wrap_content"
10+
android:layout_centerHorizontal="true"
11+
android:layout_centerVertical="true"
12+
android:text="@string/hello_world" />
13+
14+
</RelativeLayout>

0 commit comments

Comments
 (0)