mirror of
https://code.briarproject.org/briar/briar.git
synced 2026-02-16 12:49:55 +01:00
Add (non-functional) button for scanning QR code
This commit is contained in:
@@ -11,6 +11,7 @@ import android.view.View;
|
|||||||
import android.view.ViewGroup;
|
import android.view.ViewGroup;
|
||||||
import android.widget.Button;
|
import android.widget.Button;
|
||||||
import android.widget.EditText;
|
import android.widget.EditText;
|
||||||
|
import android.widget.Toast;
|
||||||
|
|
||||||
import org.briarproject.bramble.api.nullsafety.NotNullByDefault;
|
import org.briarproject.bramble.api.nullsafety.NotNullByDefault;
|
||||||
import org.briarproject.briar.R;
|
import org.briarproject.briar.R;
|
||||||
@@ -71,6 +72,11 @@ public class ContactLinkInputFragment extends BaseFragment
|
|||||||
addButton = v.findViewById(R.id.addButton);
|
addButton = v.findViewById(R.id.addButton);
|
||||||
addButton.setOnClickListener(view -> onAddButtonClicked());
|
addButton.setOnClickListener(view -> onAddButtonClicked());
|
||||||
|
|
||||||
|
Button scanCodeButton = v.findViewById(R.id.scanCodeButton);
|
||||||
|
scanCodeButton.setOnClickListener(view -> Toast
|
||||||
|
.makeText(getContext(), "Not implemented!", Toast.LENGTH_SHORT)
|
||||||
|
.show());
|
||||||
|
|
||||||
linkInput.setText(getArguments().getString("link"));
|
linkInput.setText(getArguments().getString("link"));
|
||||||
|
|
||||||
return v;
|
return v;
|
||||||
|
|||||||
@@ -60,4 +60,34 @@
|
|||||||
app:layout_constraintTop_toBottomOf="@id/linkInput"
|
app:layout_constraintTop_toBottomOf="@id/linkInput"
|
||||||
tools:enabled="true"/>
|
tools:enabled="true"/>
|
||||||
|
|
||||||
|
<TextView
|
||||||
|
android:id="@+id/textView3"
|
||||||
|
android:layout_width="wrap_content"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:layout_marginEnd="8dp"
|
||||||
|
android:layout_marginLeft="8dp"
|
||||||
|
android:layout_marginRight="8dp"
|
||||||
|
android:layout_marginStart="8dp"
|
||||||
|
android:layout_marginTop="16dp"
|
||||||
|
android:text="or"
|
||||||
|
android:textSize="18sp"
|
||||||
|
app:layout_constraintEnd_toEndOf="parent"
|
||||||
|
app:layout_constraintStart_toStartOf="parent"
|
||||||
|
app:layout_constraintTop_toBottomOf="@+id/addButton"/>
|
||||||
|
|
||||||
|
<Button
|
||||||
|
android:id="@+id/scanCodeButton"
|
||||||
|
style="@style/BriarButton"
|
||||||
|
android:layout_width="wrap_content"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:layout_marginEnd="8dp"
|
||||||
|
android:layout_marginStart="8dp"
|
||||||
|
android:layout_marginTop="16dp"
|
||||||
|
android:drawableLeft="@drawable/ic_qr_code"
|
||||||
|
android:drawablePadding="8dp"
|
||||||
|
android:text="Scan QR Code"
|
||||||
|
app:layout_constraintEnd_toEndOf="parent"
|
||||||
|
app:layout_constraintStart_toStartOf="parent"
|
||||||
|
app:layout_constraintTop_toBottomOf="@+id/textView3"/>
|
||||||
|
|
||||||
</android.support.constraint.ConstraintLayout>
|
</android.support.constraint.ConstraintLayout>
|
||||||
|
|||||||
Reference in New Issue
Block a user