Skip to content

Commit

Permalink
treehouses bridge fix (Fixes #258) (#268)
Browse files Browse the repository at this point in the history
  • Loading branch information
rrijal53 authored and dogi committed May 9, 2019
1 parent 9899b9d commit 4cba0f6
Show file tree
Hide file tree
Showing 2 changed files with 16 additions and 15 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -21,8 +21,8 @@ public ViewHolderBridge(View v, final HomeInteractListener listener) {
v.findViewById(R.id.btn_start_config).setOnClickListener(new View.OnClickListener() {
@Override
public void onClick(View view) {
String temp = "treehouses bridge \"" + etEssid.getText().toString() + "\" \"" + etPassword.getText().toString() + "\" ";
String overallMessage = TextUtils.isEmpty(etHotspotEssid.getText().toString()) ? temp + "\"\"" : temp + "\"" + etHotspotEssid.getText().toString() + "\"";
String temp = "treehouses bridge \"" + etEssid.getText().toString() + "\" \"" + etHotspotEssid.getText().toString() + "\" ";
String overallMessage = TextUtils.isEmpty(etPassword.getText().toString()) ? temp + "\"\"" : temp + "\"" + etPassword.getText().toString() + "\"";
overallMessage += " ";
if (!TextUtils.isEmpty(etHotspotPassword.getText().toString())) {
overallMessage += "\"" + etHotspotPassword.getText().toString() + "\"";
Expand Down
27 changes: 14 additions & 13 deletions app/src/main/res/layout/dialog_bridge.xml
Original file line number Diff line number Diff line change
Expand Up @@ -20,45 +20,46 @@

</com.google.android.material.textfield.TextInputLayout>


<com.google.android.material.textfield.TextInputLayout
android:id="@+id/tl_hotspot_essid"
android:id="@+id/tl_password"
android:layout_width="match_parent"
android:layout_height="wrap_content">
android:layout_height="wrap_content"
app:passwordToggleDrawable="@drawable/toggle_password"
app:passwordToggleEnabled="true"
app:passwordToggleTint="@color/colorPrimary">

<com.google.android.material.textfield.TextInputEditText
android:id="@+id/et_hotspot_essid"
android:id="@+id/et_password"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:editable="true"
android:fontFamily="sans-serif"
android:hint="Hotspot ESSID" />
android:hint="Password"
android:inputType="textPassword" />

</com.google.android.material.textfield.TextInputLayout>


<com.google.android.material.textfield.TextInputLayout
android:id="@+id/tl_password"
android:id="@+id/tl_hotspot_essid"
android:layout_width="match_parent"
android:layout_height="wrap_content"
app:passwordToggleDrawable="@drawable/toggle_password"
app:passwordToggleEnabled="true"
app:passwordToggleTint="@color/colorPrimary">
android:layout_height="wrap_content">

<com.google.android.material.textfield.TextInputEditText
android:id="@+id/et_password"
android:id="@+id/et_hotspot_essid"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:editable="true"
android:fontFamily="sans-serif"
android:hint="Password"
android:inputType="textPassword" />
android:hint="Hotspot ESSID" />

</com.google.android.material.textfield.TextInputLayout>

<com.google.android.material.textfield.TextInputLayout
android:id="@+id/tl_hotspot_password"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:padding="@dimen/padding_normal"
app:passwordToggleDrawable="@drawable/toggle_password"
app:passwordToggleEnabled="true"
app:passwordToggleTint="@color/colorPrimary">
Expand Down

0 comments on commit 4cba0f6

Please sign in to comment.