Skip to content

Commit 8477e67

Browse files
author
simon
committed
-modified color theme
1 parent 2a1683f commit 8477e67

18 files changed

Lines changed: 61 additions & 28 deletions

app/src/main/java/org/twistedappdeveloper/opcclient/SessionActivity.java

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,6 @@
11
package org.twistedappdeveloper.opcclient;
22

3+
import android.annotation.SuppressLint;
34
import android.app.Dialog;
45
import android.app.ProgressDialog;
56
import android.content.DialogInterface;
@@ -141,7 +142,7 @@ public void onClick(View v) {
141142
CreateSubscriptionRequest req = new CreateSubscriptionRequest(null, requestedPublishInterval, requestedLifetimeCount, requestedMaxKeepAliveCount, maxNotificationPerPublish, publishingEnabled, priority);
142143
ThreadCreateSubscription t = new ThreadCreateSubscription(sessionElement, req);
143144
progressDialog = ProgressDialog.show(SessionActivity.this, getString(R.string.TentativoDiConnessione), getString(R.string.CreazioneSottoscrizione), true);
144-
Handler handler_subscription = new Handler() {
145+
@SuppressLint("HandlerLeak") Handler handler_subscription = new Handler() {
145146
@Override
146147
public void handleMessage(Message msg) {
147148
progressDialog.dismiss();
@@ -221,7 +222,7 @@ else if (value.toLowerCase().compareTo("false") == 0)
221222
t = new ThreadWrite(sessionElement.getSession(), namespace, nodeid, Attributes.Value, value_write);
222223
else
223224
t = new ThreadWrite(sessionElement.getSession(), namespace, nodeid_string, Attributes.Value, value_write);
224-
Handler handler = new Handler() {
225+
@SuppressLint("HandlerLeak") Handler handler = new Handler() {
225226
@Override
226227
public void handleMessage(Message msg) {
227228
progressDialog.dismiss();

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

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -24,5 +24,5 @@
2424
android:layout_height="match_parent"
2525
android:layout_below="@+id/textView5"
2626
android:layout_centerHorizontal="true"
27-
android:background="#b4b2b2"/>
27+
android:background="@color/colorPrimaryDark"/>
2828
</RelativeLayout>

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

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,8 @@
2424
android:layout_height="wrap_content"
2525
android:layout_below="@+id/edtURL"
2626
android:layout_centerHorizontal="true"
27-
android:text="@string/DiscoveryEndpoints" />
27+
android:text="@string/DiscoveryEndpoints"
28+
style="@style/Widget.AppCompat.Button.Colored"/>
2829

2930
<TextView
3031
android:id="@+id/textView"
@@ -55,7 +56,7 @@
5556
android:layout_height="match_parent"
5657
android:layout_alignParentStart="true"
5758
android:layout_below="@+id/textView2"
58-
android:background="#b4b2b2"
59+
android:background="@color/colorPrimaryDark"
5960
android:scrollbars="vertical"
6061
android:visibility="visible" />
6162

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

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -39,5 +39,5 @@
3939
android:id="@+id/listMonitoredRead"
4040
android:layout_width="match_parent"
4141
android:layout_height="match_parent"
42-
android:background="#b4b2b2"/>
42+
android:background="@color/colorPrimaryDark"/>
4343
</LinearLayout>

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

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,11 +22,12 @@
2222
android:layout_width="match_parent"
2323
android:layout_height="wrap_content"
2424
android:textAlignment="center"
25+
android:textStyle="bold"
2526
tools:text="TextView" />
2627

2728
<ListView
2829
android:id="@+id/listMonitoraggio"
2930
android:layout_width="match_parent"
3031
android:layout_height="match_parent"
31-
android:background="#b4b2b2" />
32+
android:background="@color/colorPrimaryDark" />
3233
</LinearLayout>

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

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,8 @@
2222
android:id="@+id/btnNewRead"
2323
android:layout_width="match_parent"
2424
android:layout_height="wrap_content"
25-
android:text="@string/inseriscidatilettura" />
25+
android:text="@string/inseriscidatilettura"
26+
style="@style/Widget.AppCompat.Button.Colored"/>
2627

2728
<TextView
2829
android:id="@+id/txtelencoletture"
@@ -38,5 +39,5 @@
3839
android:id="@+id/list_read"
3940
android:layout_width="match_parent"
4041
android:layout_height="match_parent"
41-
android:background="#b4b2b2" />
42+
android:background="@color/colorPrimaryDark" />
4243
</LinearLayout>

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

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@
1111
android:layout_width="match_parent"
1212
android:layout_height="match_parent"
1313
android:layout_below="@+id/textView3"
14-
android:background="#b4b2b2"
14+
android:background="@color/colorPrimaryDark"
1515
android:scrollbars="vertical"
1616
android:visibility="visible" />
1717

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

Lines changed: 10 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -56,32 +56,37 @@
5656
android:layout_width="match_parent"
5757
android:layout_height="wrap_content"
5858
android:text="@string/read"
59-
android:textAlignment="center" />
59+
android:textAlignment="center"
60+
style="@style/Widget.AppCompat.Button.Colored"/>
6061

6162
<Button
6263
android:id="@+id/btnWrite"
6364
android:layout_width="match_parent"
6465
android:layout_height="wrap_content"
65-
android:text="@string/write" />
66+
android:text="@string/write"
67+
style="@style/Widget.AppCompat.Button.Colored"/>
6668

6769
<Button
6870
android:id="@+id/btnBrowse"
6971
android:layout_width="match_parent"
7072
android:layout_height="wrap_content"
7173
android:text="@string/browse"
72-
android:textAlignment="center" />
74+
android:textAlignment="center"
75+
style="@style/Widget.AppCompat.Button.Colored"/>
7376

7477
<Button
7578
android:id="@+id/btnSubscribe"
7679
android:layout_width="match_parent"
7780
android:layout_height="wrap_content"
7881
android:text="@string/subscribe"
79-
android:textAlignment="center" />
82+
android:textAlignment="center"
83+
style="@style/Widget.AppCompat.Button.Colored"/>
8084

8185
<Button
8286
android:id="@+id/btnMonitoring"
8387
android:layout_width="match_parent"
8488
android:layout_height="wrap_content"
85-
android:text="@string/monitoraggio" />
89+
android:text="@string/monitoraggio"
90+
style="@style/Widget.AppCompat.Button.Colored"/>
8691

8792
</LinearLayout>

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

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -45,13 +45,14 @@
4545
android:layout_height="wrap_content"
4646
android:layout_below="@+id/txtParametriSottoscrizione"
4747
android:layout_centerHorizontal="true"
48-
android:text="@string/creamonitem" />
48+
android:text="@string/creamonitem"
49+
style="@style/Widget.AppCompat.Button.Colored"/>
4950

5051
<ListView
5152
android:id="@+id/listMonitoredItem"
5253
android:layout_width="match_parent"
5354
android:layout_height="match_parent"
5455
android:layout_alignParentStart="true"
5556
android:layout_below="@+id/btnCreateMonitoredItem"
56-
android:background="#b4b2b2"/>
57+
android:background="@color/colorPrimaryDark"/>
5758
</RelativeLayout>

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

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -159,7 +159,8 @@
159159
android:id="@+id/btnOkMonitoredItem"
160160
android:layout_width="match_parent"
161161
android:layout_height="wrap_content"
162-
android:text="@android:string/ok" />
162+
android:text="@android:string/ok"
163+
style="@style/Widget.AppCompat.Button.Colored"/>
163164

164165
</LinearLayout>
165166
</ScrollView>

0 commit comments

Comments
 (0)