Skip to content

Commit e8f4a0c

Browse files
Kunal RaiCloudyPadmal
authored andcommitted
Hard coded,redundant code removed (#1808)
1 parent 5bba124 commit e8f4a0c

14 files changed

+52
-35
lines changed

app/src/main/res/layout/activity_maps.xml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@
55
android:layout_height="match_parent"
66
tools:context="io.pslab.activity.MapsActivity">
77

8-
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
8+
<LinearLayout
99
android:layout_width="match_parent"
1010
android:layout_height="match_parent"
1111
android:orientation="vertical">

app/src/main/res/layout/activity_oscilloscope.xml

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -78,7 +78,6 @@
7878
android:id="@+id/chart_yaxis_layout1"
7979
android:layout_width="wrap_content"
8080
android:layout_height="match_parent"
81-
android:layout_alignParentLeft="true"
8281
android:layout_alignParentStart="true"
8382
android:layout_alignParentTop="true"
8483
android:background="@color/black"
@@ -128,7 +127,6 @@
128127
android:layout_width="wrap_content"
129128
android:layout_height="match_parent"
130129
android:layout_alignParentEnd="true"
131-
android:layout_alignParentRight="true"
132130
android:layout_centerVertical="true"
133131
android:background="@color/black"
134132
android:foregroundGravity="right"

app/src/main/res/layout/activity_robotic_arm.xml

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -43,7 +43,7 @@
4343

4444
<LinearLayout
4545
android:id="@+id/servo_timeline_controls"
46-
android:layout_width="10dp"
46+
android:layout_width="@dimen/robotic_arm_margin"
4747
android:layout_height="match_parent"
4848
android:layout_weight="0.1"
4949
android:background="@color/colorPrimary"
@@ -54,28 +54,28 @@
5454
android:id="@+id/timeline_play_pause_button"
5555
android:layout_width="@dimen/robotic_arm_width"
5656
android:layout_height="@dimen/robotic_arm_height"
57-
android:layout_margin="@dimen/robotic_arm_margin_7"
57+
android:layout_margin="@dimen/robotic_arm_margin_small"
5858
android:background="@drawable/ic_play_arrow_white_24dp" />
5959

6060
<Button
6161
android:id="@+id/timeline_stop_button"
6262
android:layout_width="@dimen/robotic_arm_width"
6363
android:layout_height="@dimen/robotic_arm_height"
64-
android:layout_margin="@dimen/robotic_arm_margin_10"
64+
android:layout_margin="@dimen/robotic_arm_margin"
6565
android:background="@drawable/ic_record_stop_white" />
6666

6767
<Button
6868
android:id="@+id/timeline_save_button"
6969
android:layout_width="@dimen/robotic_arm_width"
7070
android:layout_height="@dimen/robotic_arm_height"
71-
android:layout_margin="@dimen/robotic_arm_margin_7"
71+
android:layout_margin="@dimen/robotic_arm_margin_small"
7272
android:background="@drawable/menu_icon_save" />
7373

7474
<Button
7575
android:id="@+id/timeline_guide_button"
7676
android:layout_width="@dimen/robotic_arm_width"
7777
android:layout_height="@dimen/robotic_arm_height"
78-
android:layout_margin="@dimen/robotic_arm_margin_10"
78+
android:layout_margin="@dimen/robotic_arm_margin"
7979
android:background="@drawable/menu_icon_guide" />
8080
</LinearLayout>
8181
</LinearLayout>

app/src/main/res/layout/activity_sensor_graph_view.xml

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -44,10 +44,9 @@
4444
android:id="@+id/chart_xaxis_layout"
4545
android:layout_width="match_parent"
4646
android:layout_height="wrap_content"
47-
android:layout_alignParentLeft="true"
4847
android:layout_alignParentStart="true"
4948
android:layout_alignParentTop="true"
50-
android:background="#000"
49+
android:background="@color/black"
5150
android:orientation="vertical">
5251

5352
<TextView

app/src/main/res/layout/activity_thermometer.xml

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@
1818
android:baselineAligned="false">
1919

2020
<LinearLayout
21-
android:layout_width="0dp"
21+
android:layout_width="@dimen/thermo_width_0"
2222
android:layout_height="match_parent"
2323
android:layout_weight="3"
2424
android:gravity="center_horizontal|center_vertical"
@@ -27,7 +27,7 @@
2727
<TextView
2828
android:id="@+id/label_thermo_sensor"
2929
style="@style/thermo_meter_stat_heading"
30-
android:paddingBottom="5dp"
30+
android:paddingBottom="@dimen/thermo_padding"
3131
android:textSize="@dimen/thermo_sensor_label_title_size" />
3232

3333
<TextView
@@ -128,7 +128,6 @@
128128
android:layout_height="match_parent"
129129
android:layout_below="@+id/chart_xaxis_layout_thermo"
130130
android:layout_toEndOf="@+id/chart_yaxis_layout_hmc_thermo"
131-
android:layout_toRightOf="@+id/chart_yaxis_layout_hmc_thermo"
132131
android:background="@color/black" />
133132
</RelativeLayout>
134133

app/src/main/res/layout/fragment_lux_meter_data.xml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@
1818
android:baselineAligned="false">
1919

2020
<LinearLayout
21-
android:layout_width="0dp"
21+
android:layout_width="@dimen/lux_width_0"
2222
android:layout_height="match_parent"
2323
android:layout_weight="3"
2424
android:gravity="center_horizontal|center_vertical"

app/src/main/res/layout/fragment_timebase_tigger.xml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -9,8 +9,8 @@
99
<TableLayout
1010
android:layout_width="match_parent"
1111
android:layout_height="match_parent"
12-
android:layout_marginEnd="8dp"
13-
android:layout_marginStart="8dp">
12+
android:layout_marginEnd="@dimen/timebase_margin_end"
13+
android:layout_marginStart="@dimen/timebase_margin_start">
1414

1515
<TableRow
1616
android:layout_width="match_parent"

app/src/main/res/layout/robotic_arm_timeline_textview.xml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@
99
android:layout_width="wrap_content"
1010
android:layout_height="wrap_content"
1111
android:textColor="@color/white"
12-
android:textSize="24sp" />
12+
android:textSize="@dimen/robotic_arm_text_size" />
1313

1414
<TextView
1515
android:id="@+id/timeline_box_time_text"

app/src/main/res/layout/sensor_list_item.xml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,6 @@
1010
android:textAlignment="center"
1111
android:textAllCaps="true"
1212
android:textColor="@color/white"
13-
android:textSize="14sp"
13+
android:textSize="@dimen/sensorlist_text_size"
1414
android:textStyle="bold"
1515
/>

app/src/main/res/layout/sensor_main.xml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -57,7 +57,7 @@
5757
android:text="@string/select_sensor"
5858
android:textAllCaps="true"
5959
android:textColor="@color/black"
60-
android:textSize="18sp"
60+
android:textSize="@dimen/text_size_sensor_list"
6161
android:textStyle="bold" />
6262

6363
<ListView

0 commit comments

Comments
 (0)