Merge branch 'ashlk/nitterizeme-ui_changes' into develop

# Conflicts:
#	app/src/main/res/values/strings.xml
This commit is contained in:
Thomas 2020-02-29 10:24:40 +01:00
commit f8d22d7548
5 changed files with 852 additions and 280 deletions

View File

@ -35,6 +35,7 @@ import android.widget.TextView;
import androidx.appcompat.app.AppCompatActivity;
import androidx.appcompat.widget.SwitchCompat;
import androidx.appcompat.widget.Toolbar;
import androidx.constraintlayout.widget.Group;
import androidx.recyclerview.widget.LinearLayoutManager;
import androidx.recyclerview.widget.RecyclerView;
@ -50,17 +51,17 @@ public class MainActivity extends AppCompatActivity {
public static final String APP_PREFS = "app_prefs";
@SuppressWarnings("unused")
public static String TAG = "NitterizeMe";
public static String SET_NITTER_HOST = "set_nitter_host";
public static final String SET_NITTER_HOST = "set_nitter_host";
public static String DEFAULT_NITTER_HOST = "nitter.net";
public static String SET_INVIDIOUS_HOST = "set_invidious_host";
public static final String SET_INVIDIOUS_HOST = "set_invidious_host";
public static String DEFAULT_INVIDIOUS_HOST = "invidio.us";
public static String SET_INVIDIOUS_ENABLED = "set_invidious_enabled";
public static String SET_NITTER_ENABLED = "set_nitter_enabled";
public static String SET_OSM_ENABLED = "set_osm_enabled";
public static String SET_OSM_HOST = "set_osm_host";
public static final String SET_OSM_HOST = "set_osm_host";
public static String DEFAULT_OSM_HOST = "www.openstreetmap.org";
public static String SET_BIBLIOGRAM_ENABLED = "set_bibliogram_enabled";
public static String SET_BIBLIOGRAM_HOST = "set_bibliogram_host";
public static final String SET_BIBLIOGRAM_HOST = "set_bibliogram_host";
public static String DEFAULT_BIBLIOGRAM_HOST = "bibliogram.art";
public static String SET_GEO_URIS = "set_geo_uris";
//Supported domains
@ -92,6 +93,11 @@ public class MainActivity extends AppCompatActivity {
private RecyclerView list_apps;
private String[] domains;
private String nitterHost;
private String invidiousHost;
private String bibliogramHost;
private String osmHost;
@Override
protected void onCreate(Bundle savedInstanceState) {
super.onCreate(savedInstanceState);
@ -122,16 +128,28 @@ public class MainActivity extends AppCompatActivity {
SharedPreferences sharedpreferences = getSharedPreferences(APP_PREFS, Context.MODE_PRIVATE);
TextView current_instance_nitter = findViewById(R.id.current_instance_nitter);
TextView current_instance_invidious = findViewById(R.id.current_instance_invidious);
TextView current_instance_bibliogram = findViewById(R.id.current_instance_bibliogram);
TextView current_instance_osm = findViewById(R.id.current_instance_osm);
TextInputEditText nitter_instance = findViewById(R.id.nitter_instance);
TextInputEditText invidious_instance = findViewById(R.id.invidious_instance);
TextInputEditText bibliogram_instance = findViewById(R.id.bibliogram_instance);
TextInputEditText osm_instance = findViewById(R.id.osm_instance);
TextInputLayout invidious_instance_container = findViewById(R.id.invidious_instance_container);
TextInputLayout nitter_instance_container = findViewById(R.id.nitter_instance_container);
TextInputLayout bibliogram_instance_container = findViewById(R.id.bibliogram_instance_container);
TextInputLayout osm_instance_container = findViewById(R.id.osm_instance_container);
Group invidious_current_group = findViewById(R.id.group_current_invidious);
Group nitter_current_group = findViewById(R.id.group_current_nitter);
Group bibliogram_current_group = findViewById(R.id.group_current_bibliogram);
Group osm_current_group = findViewById(R.id.group_current_osm);
Group invidious_custom_group = findViewById(R.id.group_custom_invidious);
Group nitter_custom_group = findViewById(R.id.group_custom_nitter);
Group bibliogram_custom_group = findViewById(R.id.group_custom_bibliogram);
Group osm_custom_group = findViewById(R.id.group_custom_osm);
SwitchCompat enable_nitter = findViewById(R.id.enable_nitter);
@ -139,6 +157,13 @@ public class MainActivity extends AppCompatActivity {
SwitchCompat enable_bibliogram = findViewById(R.id.enable_bibliogram);
SwitchCompat enable_osm = findViewById(R.id.enable_osm);
ImageButton expand_instance_nitter = findViewById(R.id.button_expand_instance_nitter);
ImageButton expand_instance_invidious = findViewById(R.id.button_expand_instance_invidious);
ImageButton expand_instance_bibliogram = findViewById(R.id.button_expand_instance_bibliogram);
ImageButton expand_instance_osm = findViewById(R.id.button_expand_instance_osm);
boolean nitter_enabled = sharedpreferences.getBoolean(SET_NITTER_ENABLED, true);
boolean invidious_enabled = sharedpreferences.getBoolean(SET_INVIDIOUS_ENABLED, true);
boolean osm_enabled = sharedpreferences.getBoolean(SET_OSM_ENABLED, true);
@ -150,94 +175,214 @@ public class MainActivity extends AppCompatActivity {
enable_bibliogram.setChecked(bibliogram_enabled);
enable_osm.setChecked(osm_enabled);
Button button_save = findViewById(R.id.button_save);
ImageButton save_instance_nitter = findViewById(R.id.button_save_instance_nitter);
ImageButton save_instance_invidious = findViewById(R.id.button_save_instance_invidious);
ImageButton save_instance_bibliogram = findViewById(R.id.button_save_instance_bibliogram);
ImageButton save_instance_osm = findViewById(R.id.button_save_instance_osm);
CheckBox enable_geo_uris = findViewById(R.id.enable_geo_uris);
list_apps = findViewById(R.id.list_apps);
String nitterHost = sharedpreferences.getString(SET_NITTER_HOST, null);
String invidiousHost = sharedpreferences.getString(SET_INVIDIOUS_HOST, null);
String bibliogramHost = sharedpreferences.getString(SET_BIBLIOGRAM_HOST, null);
String osmHost = sharedpreferences.getString(SET_OSM_HOST, null);
nitterHost = sharedpreferences.getString(SET_NITTER_HOST, null);
invidiousHost = sharedpreferences.getString(SET_INVIDIOUS_HOST, null);
bibliogramHost = sharedpreferences.getString(SET_BIBLIOGRAM_HOST, null);
osmHost = sharedpreferences.getString(SET_OSM_HOST, null);
invidious_instance_container.setVisibility(invidious_enabled ? View.VISIBLE : View.GONE);
nitter_instance_container.setVisibility(nitter_enabled ? View.VISIBLE : View.GONE);
bibliogram_instance_container.setVisibility(bibliogram_enabled ? View.VISIBLE : View.GONE);
osm_instance_container.setVisibility(osm_enabled ? View.VISIBLE : View.GONE);
invidious_current_group.setVisibility(invidious_enabled ? View.VISIBLE : View.GONE);
nitter_current_group.setVisibility(nitter_enabled ? View.VISIBLE : View.GONE);
bibliogram_current_group.setVisibility(bibliogram_enabled ? View.VISIBLE : View.GONE);
osm_current_group.setVisibility((osm_enabled && geouri_enabled) ? View.VISIBLE : View.GONE);
enable_geo_uris.setVisibility(osm_enabled ? View.VISIBLE : View.GONE);
enable_invidious.setOnCheckedChangeListener((buttonView, isChecked) -> {
SharedPreferences.Editor editor = sharedpreferences.edit();
editor.putBoolean(SET_INVIDIOUS_ENABLED, isChecked);
editor.apply();
invidious_instance_container.setVisibility(isChecked ? View.VISIBLE : View.GONE);
invidious_current_group.setVisibility(isChecked ? View.VISIBLE : View.GONE);
invidious_custom_group.setVisibility(View.GONE);
expand_instance_invidious.setRotation(0);
});
enable_nitter.setOnCheckedChangeListener((buttonView, isChecked) -> {
SharedPreferences.Editor editor = sharedpreferences.edit();
editor.putBoolean(SET_NITTER_ENABLED, isChecked);
editor.apply();
nitter_instance_container.setVisibility(isChecked ? View.VISIBLE : View.GONE);
nitter_current_group.setVisibility(isChecked ? View.VISIBLE : View.GONE);
nitter_custom_group.setVisibility(View.GONE);
expand_instance_nitter.setRotation(0);
});
enable_bibliogram.setOnCheckedChangeListener((buttonView, isChecked) -> {
SharedPreferences.Editor editor = sharedpreferences.edit();
editor.putBoolean(SET_BIBLIOGRAM_ENABLED, isChecked);
editor.apply();
bibliogram_instance_container.setVisibility(isChecked ? View.VISIBLE : View.GONE);
bibliogram_current_group.setVisibility(isChecked ? View.VISIBLE : View.GONE);
bibliogram_custom_group.setVisibility(View.GONE);
expand_instance_bibliogram.setRotation(0);
});
enable_osm.setOnCheckedChangeListener((buttonView, isChecked) -> {
SharedPreferences.Editor editor = sharedpreferences.edit();
editor.putBoolean(SET_OSM_ENABLED, isChecked);
editor.apply();
osm_current_group.setVisibility(isChecked ? View.VISIBLE : View.GONE);
osm_custom_group.setVisibility(View.GONE);
enable_geo_uris.setVisibility(isChecked ? View.VISIBLE : View.GONE);
expand_instance_osm.setRotation(0);
boolean geo = sharedpreferences.getBoolean(SET_GEO_URIS, false);
if (geo) {
osm_instance_container.setVisibility(View.GONE);
} else {
osm_instance_container.setVisibility(isChecked ? View.VISIBLE : View.GONE);
if (isChecked) {
if (geo) {
osm_current_group.setVisibility(View.GONE);
osm_custom_group.setVisibility(View.GONE);
} else {
osm_current_group.setVisibility(View.VISIBLE);
}
}
});
expand_instance_nitter.setOnClickListener(v -> {
boolean custom_instance_visibility = nitter_custom_group.getVisibility() == View.VISIBLE;
if (custom_instance_visibility) {
expand_instance_nitter.setRotation(0f);
nitter_custom_group.setVisibility(View.GONE);
} else {
expand_instance_nitter.setRotation(180f);
nitter_custom_group.setVisibility(View.VISIBLE);
}
if (nitterHost != null) {
nitter_instance.setText(nitterHost);
} else {
nitter_instance.setText("");
}
});
expand_instance_invidious.setOnClickListener(v -> {
boolean custom_instance_visibility = invidious_custom_group.getVisibility() == View.VISIBLE;
if (custom_instance_visibility) {
expand_instance_invidious.setRotation(0f);
invidious_custom_group.setVisibility(View.GONE);
} else {
expand_instance_invidious.setRotation(180f);
invidious_custom_group.setVisibility(View.VISIBLE);
}
if (invidiousHost != null) {
invidious_instance.setText(invidiousHost);
} else {
invidious_instance.setText("");
}
});
expand_instance_bibliogram.setOnClickListener(v -> {
boolean custom_instance_visibility = bibliogram_custom_group.getVisibility() == View.VISIBLE;
if (custom_instance_visibility) {
expand_instance_bibliogram.setRotation(0f);
bibliogram_custom_group.setVisibility(View.GONE);
} else {
expand_instance_bibliogram.setRotation(180f);
bibliogram_custom_group.setVisibility(View.VISIBLE);
}
if (bibliogramHost != null) {
bibliogram_instance.setText(bibliogramHost);
} else {
bibliogram_instance.setText("");
}
});
expand_instance_osm.setOnClickListener(v -> {
boolean custom_instance_visibility = osm_custom_group.getVisibility() == View.VISIBLE;
if (custom_instance_visibility) {
expand_instance_osm.setRotation(0f);
osm_custom_group.setVisibility(View.GONE);
} else {
expand_instance_osm.setRotation(180f);
osm_custom_group.setVisibility(View.VISIBLE);
}
if (osmHost != null) {
osm_instance.setText(osmHost);
} else {
osm_instance.setText("");
}
});
if (nitterHost != null) {
nitter_instance.setText(nitterHost);
current_instance_nitter.setText(nitterHost);
} else {
current_instance_nitter.setText(DEFAULT_NITTER_HOST);
}
if (invidiousHost != null) {
invidious_instance.setText(invidiousHost);
current_instance_invidious.setText(invidiousHost);
} else {
current_instance_invidious.setText(DEFAULT_INVIDIOUS_HOST);
}
if (bibliogramHost != null) {
bibliogram_instance.setText(bibliogramHost);
current_instance_bibliogram.setText(bibliogramHost);
} else {
current_instance_bibliogram.setText(DEFAULT_BIBLIOGRAM_HOST);
}
if (osmHost != null) {
osm_instance.setText(osmHost);
current_instance_osm.setText(osmHost);
} else {
current_instance_osm.setText(DEFAULT_OSM_HOST);
}
enable_geo_uris.setChecked(geouri_enabled);
if (geouri_enabled) {
osm_instance_container.setVisibility(View.GONE);
osm_current_group.setVisibility(View.GONE);
osm_custom_group.setVisibility(View.GONE);
} else {
osm_instance_container.setVisibility(View.VISIBLE);
osm_current_group.setVisibility(View.VISIBLE);
}
button_save.setOnClickListener(v -> {
save_instance_nitter.setOnClickListener(v -> {
SharedPreferences.Editor editor = sharedpreferences.edit();
if (nitter_instance.getText() != null && nitter_instance.getText().toString().trim().length() > 0) {
editor.putString(SET_NITTER_HOST, nitter_instance.getText().toString().toLowerCase().trim());
String custom_instance = nitter_instance.getText().toString().toLowerCase().trim();
editor.putString(SET_NITTER_HOST, custom_instance);
current_instance_nitter.setText(custom_instance);
} else {
editor.putString(SET_NITTER_HOST, null);
}
if (invidious_instance.getText() != null && invidious_instance.getText().toString().trim().length() > 0) {
editor.putString(SET_INVIDIOUS_HOST, invidious_instance.getText().toString().toLowerCase().trim());
} else {
editor.putString(SET_INVIDIOUS_HOST, null);
}
if (bibliogram_instance.getText() != null && bibliogram_instance.getText().toString().trim().length() > 0) {
editor.putString(SET_BIBLIOGRAM_HOST, bibliogram_instance.getText().toString().toLowerCase().trim());
} else {
editor.putString(SET_BIBLIOGRAM_HOST, null);
}
if (osm_instance.getText() != null && osm_instance.getText().toString().trim().length() > 0) {
editor.putString(SET_OSM_HOST, osm_instance.getText().toString().toLowerCase().trim());
} else {
editor.putString(SET_OSM_HOST, null);
current_instance_nitter.setText(DEFAULT_NITTER_HOST);
}
editor.apply();
});
save_instance_invidious.setOnClickListener(v -> {
SharedPreferences.Editor editor = sharedpreferences.edit();
if (invidious_instance.getText() != null && invidious_instance.getText().toString().trim().length() > 0) {
String custom_instance = invidious_instance.getText().toString().toLowerCase().trim();
editor.putString(SET_INVIDIOUS_HOST, custom_instance);
current_instance_invidious.setText(custom_instance);
} else {
editor.putString(SET_INVIDIOUS_HOST, null);
current_instance_invidious.setText(DEFAULT_INVIDIOUS_HOST);
}
editor.apply();
});
save_instance_bibliogram.setOnClickListener(v -> {
SharedPreferences.Editor editor = sharedpreferences.edit();
if (bibliogram_instance.getText() != null && bibliogram_instance.getText().toString().trim().length() > 0) {
String custom_instance = bibliogram_instance.getText().toString().toLowerCase().trim();
editor.putString(SET_BIBLIOGRAM_HOST, custom_instance);
current_instance_bibliogram.setText(custom_instance);
} else {
editor.putString(SET_BIBLIOGRAM_HOST, null);
current_instance_bibliogram.setText(DEFAULT_BIBLIOGRAM_HOST);
}
editor.apply();
});
save_instance_osm.setOnClickListener(v -> {
SharedPreferences.Editor editor = sharedpreferences.edit();
if (osm_instance.getText() != null && osm_instance.getText().toString().trim().length() > 0) {
String custom_instance = osm_instance.getText().toString().toLowerCase().trim();
editor.putString(SET_OSM_HOST, custom_instance);
} else {
editor.putString(SET_OSM_HOST, null);
current_instance_osm.setText(DEFAULT_OSM_HOST);
}
editor.apply();
View parentLayout = findViewById(android.R.id.content);
Snackbar.make(parentLayout, R.string.instances_saved, Snackbar.LENGTH_LONG).show();
});
Button configure = findViewById(R.id.configure);
@ -281,14 +426,64 @@ public class MainActivity extends AppCompatActivity {
editor.apply();
TextView osm_indications = findViewById(R.id.osm_indications);
if (isChecked) {
osm_instance_container.setVisibility(View.GONE);
osm_current_group.setVisibility(View.GONE);
osm_custom_group.setVisibility(View.GONE);
osm_indications.setText(R.string.redirect_gm_to_geo_uri);
} else {
osm_instance_container.setVisibility(View.VISIBLE);
osm_current_group.setVisibility(View.VISIBLE);
osm_indications.setText(R.string.redirect_gm_to_osm);
}
});
sharedpreferences.registerOnSharedPreferenceChangeListener(
(sharedPreferences, key) -> {
switch (key) {
case SET_NITTER_HOST:
nitterHost = sharedpreferences.getString(SET_NITTER_HOST, null);
nitter_custom_group.setVisibility(View.GONE);
if (nitterHost != null && nitterHost.trim().length() > 0)
current_instance_nitter.setText(nitterHost);
else
current_instance_nitter.setText(DEFAULT_NITTER_HOST);
expand_instance_nitter.setRotation(0f);
break;
case SET_INVIDIOUS_HOST:
invidiousHost = sharedpreferences.getString(SET_INVIDIOUS_HOST, null);
invidious_custom_group.setVisibility(View.GONE);
if (invidiousHost != null && invidiousHost.trim().length() > 0)
current_instance_invidious.setText(invidiousHost);
else
current_instance_invidious.setText(DEFAULT_INVIDIOUS_HOST);
expand_instance_invidious.setRotation(0f);
break;
case SET_BIBLIOGRAM_HOST:
bibliogramHost = sharedpreferences.getString(SET_BIBLIOGRAM_HOST, null);
bibliogram_custom_group.setVisibility(View.GONE);
if (bibliogramHost != null && bibliogramHost.trim().length() > 0)
current_instance_bibliogram.setText(bibliogramHost);
else
current_instance_bibliogram.setText(DEFAULT_BIBLIOGRAM_HOST);
expand_instance_bibliogram.setRotation(0f);
break;
case SET_OSM_HOST:
osmHost = sharedpreferences.getString(SET_OSM_HOST, null);
osm_custom_group.setVisibility(View.GONE);
if (osmHost != null && osmHost.trim().length() > 0)
current_instance_osm.setText(osmHost);
else
current_instance_osm.setText(DEFAULT_OSM_HOST);
expand_instance_osm.setRotation(0f);
break;
}
if (key.equals(SET_NITTER_HOST) || key.equals(SET_INVIDIOUS_HOST) || key.equals(SET_BIBLIOGRAM_HOST) || key.equals(SET_OSM_HOST)) {
View parentLayout = findViewById(android.R.id.content);
Snackbar.make(parentLayout, R.string.instances_saved, Snackbar.LENGTH_LONG).show();
}
}
);
appInfoAdapter = new AppInfoAdapter(appInfos);
list_apps.setAdapter(appInfoAdapter);
final LinearLayoutManager mLayoutManager;

View File

@ -23,285 +23,654 @@
android:scrollbars="none"
app:layout_behavior="@string/appbar_scrolling_view_behavior"
tools:context=".MainActivity"
tools:showIn="@layout/activity_main"
>
tools:showIn="@layout/activity_main">
<androidx.constraintlayout.widget.ConstraintLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_margin="@dimen/fab_margin"
android:animateLayoutChanges="true">
android:layout_margin="6dp"
android:orientation="vertical">
<TextView
android:id="@+id/introduction"
android:layout_width="match_parent"
android:layout_height="wrap_content"
app:layout_constraintLeft_toLeftOf="parent"
app:layout_constraintRight_toRightOf="parent"
app:layout_constraintTop_toTopOf="parent" />
<LinearLayout
<androidx.cardview.widget.CardView
android:id="@+id/nitter_container"
android:layout_width="0dp"
style="@style/containerCard"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_marginTop="20dp"
android:orientation="horizontal"
app:layout_constraintLeft_toLeftOf="parent"
app:layout_constraintRight_toRightOf="parent"
app:layout_constraintTop_toBottomOf="@+id/introduction">
app:layout_constraintBottom_toTopOf="@id/invidious_container"
app:layout_constraintTop_toTopOf="parent">
<TextView
android:id="@+id/nitter_indications"
android:layout_width="0dp"
android:layout_height="wrap_content"
android:layout_weight="1"
android:text="@string/redirect_twitter_to_nitter" />
<androidx.appcompat.widget.SwitchCompat
android:id="@+id/enable_nitter"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_gravity="center" />
</LinearLayout>
<com.google.android.material.textfield.TextInputLayout
android:id="@+id/nitter_instance_container"
android:layout_width="0dp"
android:layout_height="wrap_content"
android:layout_weight="1"
app:layout_constraintLeft_toLeftOf="parent"
app:layout_constraintRight_toRightOf="parent"
app:layout_constraintTop_toBottomOf="@+id/nitter_container">
<com.google.android.material.textfield.TextInputEditText
android:id="@+id/nitter_instance"
<androidx.constraintlayout.widget.ConstraintLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:hint="@string/custom_nitter"
android:inputType="textUri"
android:maxLines="1" />
</com.google.android.material.textfield.TextInputLayout>
android:animateLayoutChanges="true">
<androidx.constraintlayout.widget.Guideline
android:id="@+id/guide_nitter"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:orientation="horizontal"
app:layout_constraintGuide_begin="40dp" />
<LinearLayout
<View
android:id="@+id/top_part_bg_nitter"
android:layout_width="match_parent"
android:layout_height="0dp"
android:background="#404040"
app:layout_constraintBottom_toBottomOf="@id/guide_nitter"
app:layout_constraintTop_toTopOf="parent" />
<TextView
android:id="@+id/nitter_indications"
android:layout_width="0dp"
android:layout_height="wrap_content"
android:layout_marginStart="10dp"
android:layout_marginLeft="10dp"
android:text="@string/redirect_twitter_to_nitter"
app:layout_constraintBottom_toBottomOf="@id/guide_nitter"
app:layout_constraintEnd_toStartOf="@id/enable_nitter"
app:layout_constraintStart_toStartOf="parent"
app:layout_constraintTop_toTopOf="parent" />
<androidx.appcompat.widget.SwitchCompat
android:id="@+id/enable_nitter"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_gravity="center"
android:layout_marginEnd="10dp"
android:layout_marginRight="10dp"
app:layout_constraintBottom_toBottomOf="@id/guide_nitter"
app:layout_constraintEnd_toEndOf="parent"
app:layout_constraintTop_toTopOf="parent" />
<TextView
android:id="@+id/label_instance_nitter"
android:layout_width="wrap_content"
android:layout_height="30dp"
android:layout_marginStart="5dp"
android:layout_marginLeft="5dp"
android:gravity="center_vertical"
android:text="@string/instance_label"
app:layout_constraintStart_toStartOf="parent"
app:layout_constraintTop_toTopOf="@id/guide_nitter" />
<TextView
android:id="@+id/current_instance_nitter"
android:layout_width="wrap_content"
android:layout_height="30dp"
android:layout_marginStart="5dp"
android:layout_marginLeft="5dp"
android:gravity="center_vertical"
android:textColor="#fff"
app:layout_constraintStart_toEndOf="@id/label_instance_nitter"
app:layout_constraintTop_toTopOf="@id/guide_nitter" />
<ImageButton
android:id="@+id/button_expand_instance_nitter"
android:layout_width="30dp"
android:layout_height="30dp"
android:background="@null"
android:scaleType="fitCenter"
android:src="@drawable/ic_expand_more"
app:layout_constraintEnd_toEndOf="parent"
app:layout_constraintTop_toTopOf="@id/guide_nitter" />
<androidx.constraintlayout.widget.Barrier
android:id="@+id/barrier_nitter"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
app:barrierDirection="bottom"
app:constraint_referenced_ids="label_instance_nitter,current_instance_nitter,button_expand_instance_nitter" />
<com.google.android.material.textfield.TextInputLayout
android:id="@+id/nitter_instance_container"
android:layout_width="0dp"
android:layout_height="wrap_content"
android:layout_margin="5dp"
app:layout_constraintBottom_toBottomOf="parent"
app:layout_constraintEnd_toStartOf="@id/button_save_instance_nitter"
app:layout_constraintStart_toStartOf="parent"
app:layout_constraintTop_toBottomOf="@id/barrier_nitter">
<com.google.android.material.textfield.TextInputEditText
android:id="@+id/nitter_instance"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:hint="@string/custom_nitter"
android:inputType="textUri"
android:maxLines="1"
android:textSize="@dimen/custom_instance_input_text_size" />
</com.google.android.material.textfield.TextInputLayout>
<ImageButton
android:id="@+id/button_save_instance_nitter"
android:layout_width="30dp"
android:layout_height="30dp"
android:layout_margin="5dp"
android:background="@null"
android:contentDescription="@string/save"
android:src="@drawable/ic_save"
app:layout_constraintBottom_toBottomOf="parent"
app:layout_constraintEnd_toEndOf="parent"
app:layout_constraintTop_toTopOf="@id/barrier_nitter" />
<androidx.constraintlayout.widget.Group
android:id="@+id/group_current_nitter"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
app:constraint_referenced_ids="label_instance_nitter,current_instance_nitter,button_expand_instance_nitter" />
<androidx.constraintlayout.widget.Group
android:id="@+id/group_custom_nitter"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:visibility="gone"
app:constraint_referenced_ids="nitter_instance_container,button_save_instance_nitter" />
</androidx.constraintlayout.widget.ConstraintLayout>
</androidx.cardview.widget.CardView>
<androidx.cardview.widget.CardView
android:id="@+id/invidious_container"
android:layout_width="0dp"
style="@style/containerCard"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_marginTop="20dp"
android:orientation="horizontal"
app:layout_constraintLeft_toLeftOf="parent"
app:layout_constraintRight_toRightOf="parent"
app:layout_constraintTop_toBottomOf="@+id/nitter_instance_container">
app:layout_constraintBottom_toTopOf="@id/bibliogram_container"
app:layout_constraintTop_toBottomOf="@id/nitter_container">
<TextView
android:id="@+id/invidious_indications"
android:layout_width="0dp"
android:layout_height="wrap_content"
android:layout_weight="1"
android:text="@string/redirect_youtube_to_invidious" />
<androidx.appcompat.widget.SwitchCompat
android:id="@+id/enable_invidious"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_gravity="center" />
</LinearLayout>
<com.google.android.material.textfield.TextInputLayout
android:id="@+id/invidious_instance_container"
android:layout_width="0dp"
android:layout_height="wrap_content"
android:layout_weight="1"
app:layout_constraintLeft_toLeftOf="parent"
app:layout_constraintRight_toRightOf="parent"
app:layout_constraintTop_toBottomOf="@+id/invidious_container">
<com.google.android.material.textfield.TextInputEditText
android:id="@+id/invidious_instance"
<androidx.constraintlayout.widget.ConstraintLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:hint="@string/custom_invidious"
android:inputType="textUri"
android:maxLines="1" />
</com.google.android.material.textfield.TextInputLayout>
android:animateLayoutChanges="true">
<androidx.constraintlayout.widget.Guideline
android:id="@+id/guide_invidious"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:orientation="horizontal"
app:layout_constraintGuide_begin="40dp" />
<LinearLayout
<View
android:id="@+id/top_part_bg_invidious"
android:layout_width="match_parent"
android:layout_height="0dp"
android:background="#404040"
app:layout_constraintBottom_toBottomOf="@id/guide_invidious"
app:layout_constraintTop_toTopOf="parent" />
<TextView
android:id="@+id/invidious_indications"
android:layout_width="0dp"
android:layout_height="wrap_content"
android:layout_marginStart="10dp"
android:layout_marginLeft="10dp"
android:text="@string/redirect_youtube_to_invidious"
app:layout_constraintBottom_toBottomOf="@id/guide_invidious"
app:layout_constraintEnd_toStartOf="@id/enable_invidious"
app:layout_constraintStart_toStartOf="parent"
app:layout_constraintTop_toTopOf="parent" />
<androidx.appcompat.widget.SwitchCompat
android:id="@+id/enable_invidious"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_gravity="center"
android:layout_marginEnd="10dp"
android:layout_marginRight="10dp"
app:layout_constraintBottom_toBottomOf="@id/guide_invidious"
app:layout_constraintEnd_toEndOf="parent"
app:layout_constraintTop_toTopOf="parent" />
<TextView
android:id="@+id/label_instance_invidious"
android:layout_width="wrap_content"
android:layout_height="30dp"
android:layout_marginStart="5dp"
android:layout_marginLeft="5dp"
android:gravity="center_vertical"
android:text="@string/instance_label"
app:layout_constraintStart_toStartOf="parent"
app:layout_constraintTop_toTopOf="@id/guide_invidious" />
<TextView
android:id="@+id/current_instance_invidious"
android:layout_width="wrap_content"
android:layout_height="30dp"
android:layout_marginStart="5dp"
android:layout_marginLeft="5dp"
android:gravity="center_vertical"
android:textColor="#fff"
app:layout_constraintStart_toEndOf="@id/label_instance_invidious"
app:layout_constraintTop_toTopOf="@id/guide_invidious" />
<ImageButton
android:id="@+id/button_expand_instance_invidious"
android:layout_width="30dp"
android:layout_height="30dp"
android:background="@null"
android:scaleType="fitCenter"
android:src="@drawable/ic_expand_more"
app:layout_constraintEnd_toEndOf="parent"
app:layout_constraintTop_toTopOf="@id/guide_invidious" />
<androidx.constraintlayout.widget.Barrier
android:id="@+id/barrier_invidious"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
app:barrierDirection="bottom"
app:constraint_referenced_ids="label_instance_invidious,current_instance_invidious,button_expand_instance_invidious" />
<com.google.android.material.textfield.TextInputLayout
android:id="@+id/invidious_instance_container"
android:layout_width="0dp"
android:layout_height="wrap_content"
android:layout_margin="5dp"
app:layout_constraintBottom_toBottomOf="parent"
app:layout_constraintEnd_toStartOf="@id/button_save_instance_invidious"
app:layout_constraintStart_toStartOf="parent"
app:layout_constraintTop_toBottomOf="@id/barrier_invidious">
<com.google.android.material.textfield.TextInputEditText
android:id="@+id/invidious_instance"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:hint="@string/custom_invidious"
android:inputType="textUri"
android:maxLines="1"
android:textSize="@dimen/custom_instance_input_text_size" />
</com.google.android.material.textfield.TextInputLayout>
<ImageButton
android:id="@+id/button_save_instance_invidious"
android:layout_width="30dp"
android:layout_height="30dp"
android:layout_margin="5dp"
android:background="@null"
android:contentDescription="@string/save"
android:src="@drawable/ic_save"
app:layout_constraintBottom_toBottomOf="parent"
app:layout_constraintEnd_toEndOf="parent"
app:layout_constraintTop_toTopOf="@id/barrier_invidious" />
<androidx.constraintlayout.widget.Group
android:id="@+id/group_current_invidious"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
app:constraint_referenced_ids="label_instance_invidious,current_instance_invidious,button_expand_instance_invidious" />
<androidx.constraintlayout.widget.Group
android:id="@+id/group_custom_invidious"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:visibility="gone"
app:constraint_referenced_ids="invidious_instance_container,button_save_instance_invidious" />
</androidx.constraintlayout.widget.ConstraintLayout>
</androidx.cardview.widget.CardView>
<androidx.cardview.widget.CardView
android:id="@+id/bibliogram_container"
android:layout_width="0dp"
style="@style/containerCard"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_marginTop="20dp"
android:orientation="horizontal"
app:layout_constraintLeft_toLeftOf="parent"
app:layout_constraintRight_toRightOf="parent"
app:layout_constraintTop_toBottomOf="@+id/invidious_instance_container">
app:layout_constraintBottom_toTopOf="@id/osm_container"
app:layout_constraintTop_toBottomOf="@id/invidious_container">
<TextView
android:id="@+id/bibliogram_indications"
android:layout_width="0dp"
android:layout_height="wrap_content"
android:layout_weight="1"
android:text="@string/redirect_instagram_to_bibliogram"
app:layout_constraintLeft_toLeftOf="parent"
app:layout_constraintRight_toRightOf="parent"
app:layout_constraintTop_toBottomOf="@+id/invidious_container" />
<androidx.appcompat.widget.SwitchCompat
android:id="@+id/enable_bibliogram"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_gravity="center" />
</LinearLayout>
<com.google.android.material.textfield.TextInputLayout
android:id="@+id/bibliogram_instance_container"
android:layout_width="0dp"
android:layout_height="wrap_content"
android:layout_weight="1"
app:layout_constraintLeft_toLeftOf="parent"
app:layout_constraintRight_toRightOf="parent"
app:layout_constraintTop_toBottomOf="@+id/bibliogram_container">
<com.google.android.material.textfield.TextInputEditText
android:id="@+id/bibliogram_instance"
<androidx.constraintlayout.widget.ConstraintLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:hint="@string/custom_bibliogram"
android:inputType="textUri"
android:maxLines="1" />
</com.google.android.material.textfield.TextInputLayout>
android:animateLayoutChanges="true">
<androidx.constraintlayout.widget.Guideline
android:id="@+id/guide_bibliogram"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:orientation="horizontal"
app:layout_constraintGuide_begin="40dp" />
<LinearLayout
<View
android:id="@+id/top_part_bg_bibliogram"
android:layout_width="match_parent"
android:layout_height="0dp"
android:background="#404040"
app:layout_constraintBottom_toBottomOf="@id/guide_bibliogram"
app:layout_constraintTop_toTopOf="parent" />
<TextView
android:id="@+id/bibliogram_indications"
android:layout_width="0dp"
android:layout_height="wrap_content"
android:layout_marginStart="10dp"
android:layout_marginLeft="10dp"
android:text="@string/redirect_instagram_to_bibliogram"
app:layout_constraintBottom_toBottomOf="@id/guide_bibliogram"
app:layout_constraintEnd_toStartOf="@id/enable_bibliogram"
app:layout_constraintStart_toStartOf="parent"
app:layout_constraintTop_toTopOf="parent" />
<androidx.appcompat.widget.SwitchCompat
android:id="@+id/enable_bibliogram"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_gravity="center"
android:layout_marginEnd="10dp"
android:layout_marginRight="10dp"
app:layout_constraintBottom_toBottomOf="@id/guide_bibliogram"
app:layout_constraintEnd_toEndOf="parent"
app:layout_constraintTop_toTopOf="parent" />
<TextView
android:id="@+id/label_instance_bibliogram"
android:layout_width="wrap_content"
android:layout_height="30dp"
android:layout_marginStart="5dp"
android:layout_marginLeft="5dp"
android:gravity="center_vertical"
android:text="@string/instance_label"
app:layout_constraintStart_toStartOf="parent"
app:layout_constraintTop_toTopOf="@id/guide_bibliogram" />
<TextView
android:id="@+id/current_instance_bibliogram"
android:layout_width="wrap_content"
android:layout_height="30dp"
android:layout_marginStart="5dp"
android:layout_marginLeft="5dp"
android:gravity="center_vertical"
android:textColor="#fff"
app:layout_constraintStart_toEndOf="@id/label_instance_bibliogram"
app:layout_constraintTop_toTopOf="@id/guide_bibliogram" />
<ImageButton
android:id="@+id/button_expand_instance_bibliogram"
android:layout_width="30dp"
android:layout_height="30dp"
android:background="@null"
android:scaleType="fitCenter"
android:src="@drawable/ic_expand_more"
app:layout_constraintEnd_toEndOf="parent"
app:layout_constraintTop_toTopOf="@id/guide_bibliogram" />
<androidx.constraintlayout.widget.Barrier
android:id="@+id/barrier_bibliogram"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
app:barrierDirection="bottom"
app:constraint_referenced_ids="label_instance_bibliogram,current_instance_bibliogram,button_expand_instance_bibliogram" />
<com.google.android.material.textfield.TextInputLayout
android:id="@+id/bibliogram_instance_container"
android:layout_width="0dp"
android:layout_height="wrap_content"
android:layout_margin="5dp"
app:layout_constraintBottom_toBottomOf="parent"
app:layout_constraintEnd_toStartOf="@id/button_save_instance_bibliogram"
app:layout_constraintStart_toStartOf="parent"
app:layout_constraintTop_toBottomOf="@id/barrier_bibliogram">
<com.google.android.material.textfield.TextInputEditText
android:id="@+id/bibliogram_instance"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:hint="@string/custom_bibliogram"
android:inputType="textUri"
android:maxLines="1"
android:textSize="@dimen/custom_instance_input_text_size" />
</com.google.android.material.textfield.TextInputLayout>
<ImageButton
android:id="@+id/button_save_instance_bibliogram"
android:layout_width="30dp"
android:layout_height="30dp"
android:layout_margin="5dp"
android:background="@null"
android:contentDescription="@string/save"
android:src="@drawable/ic_save"
app:layout_constraintBottom_toBottomOf="parent"
app:layout_constraintEnd_toEndOf="parent"
app:layout_constraintTop_toTopOf="@id/barrier_bibliogram" />
<androidx.constraintlayout.widget.Group
android:id="@+id/group_current_bibliogram"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
app:constraint_referenced_ids="label_instance_bibliogram,current_instance_bibliogram,button_expand_instance_bibliogram" />
<androidx.constraintlayout.widget.Group
android:id="@+id/group_custom_bibliogram"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:visibility="gone"
app:constraint_referenced_ids="bibliogram_instance_container,button_save_instance_bibliogram" />
</androidx.constraintlayout.widget.ConstraintLayout>
</androidx.cardview.widget.CardView>
<androidx.cardview.widget.CardView
android:id="@+id/osm_container"
android:layout_width="0dp"
android:layout_height="wrap_content"
android:layout_marginTop="20dp"
android:orientation="horizontal"
app:layout_constraintLeft_toLeftOf="parent"
app:layout_constraintRight_toRightOf="parent"
app:layout_constraintTop_toBottomOf="@+id/bibliogram_instance_container">
<TextView
android:id="@+id/osm_indications"
android:layout_width="0dp"
android:layout_height="wrap_content"
android:layout_weight="1"
android:text="@string/redirect_gm_to_osm"
app:layout_constraintLeft_toLeftOf="parent"
app:layout_constraintRight_toRightOf="parent"
app:layout_constraintTop_toBottomOf="@+id/bibliogram_container" />
<androidx.appcompat.widget.SwitchCompat
android:id="@+id/enable_osm"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_gravity="center" />
</LinearLayout>
<com.google.android.material.textfield.TextInputLayout
android:id="@+id/osm_instance_container"
style="@style/containerCard"
android:layout_width="match_parent"
android:layout_height="wrap_content"
app:layout_constraintLeft_toLeftOf="parent"
app:layout_constraintRight_toRightOf="parent"
app:layout_constraintTop_toBottomOf="@+id/osm_container">
app:layout_constraintBottom_toTopOf="@id/buttons_container"
app:layout_constraintTop_toBottomOf="@id/bibliogram_container">
<com.google.android.material.textfield.TextInputEditText
android:id="@+id/osm_instance"
<androidx.constraintlayout.widget.ConstraintLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:hint="@string/custom_osm"
android:inputType="textUri"
android:maxLines="1" />
</com.google.android.material.textfield.TextInputLayout>
android:animateLayoutChanges="true">
<CheckBox
android:id="@+id/enable_geo_uris"
<androidx.constraintlayout.widget.Guideline
android:id="@+id/guide_osm"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:orientation="horizontal"
app:layout_constraintGuide_begin="40dp" />
<View
android:id="@+id/top_part_bg_osm"
android:layout_width="match_parent"
android:layout_height="0dp"
android:background="#404040"
app:layout_constraintBottom_toBottomOf="@id/guide_osm"
app:layout_constraintTop_toTopOf="parent" />
<TextView
android:id="@+id/osm_indications"
android:layout_width="0dp"
android:layout_height="wrap_content"
android:layout_marginStart="10dp"
android:layout_marginLeft="10dp"
android:text="@string/redirect_gm_to_osm"
app:layout_constraintBottom_toBottomOf="@id/guide_osm"
app:layout_constraintEnd_toStartOf="@id/enable_osm"
app:layout_constraintStart_toStartOf="parent"
app:layout_constraintTop_toTopOf="parent" />
<androidx.appcompat.widget.SwitchCompat
android:id="@+id/enable_osm"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_gravity="center"
android:layout_marginEnd="10dp"
android:layout_marginRight="10dp"
app:layout_constraintBottom_toBottomOf="@id/guide_osm"
app:layout_constraintEnd_toEndOf="parent"
app:layout_constraintTop_toTopOf="parent" />
<TextView
android:id="@+id/label_instance_osm"
android:layout_width="wrap_content"
android:layout_height="30dp"
android:layout_marginStart="5dp"
android:layout_marginLeft="5dp"
android:gravity="center_vertical"
android:text="@string/instance_label"
app:layout_constraintStart_toStartOf="parent"
app:layout_constraintTop_toTopOf="@id/guide_osm" />
<TextView
android:id="@+id/current_instance_osm"
android:layout_width="wrap_content"
android:layout_height="30dp"
android:layout_marginStart="5dp"
android:layout_marginLeft="5dp"
android:gravity="center_vertical"
android:textColor="#fff"
app:layout_constraintStart_toEndOf="@id/label_instance_osm"
app:layout_constraintTop_toTopOf="@id/guide_osm" />
<ImageButton
android:id="@+id/button_expand_instance_osm"
android:layout_width="30dp"
android:layout_height="30dp"
android:background="@null"
android:scaleType="fitCenter"
android:src="@drawable/ic_expand_more"
app:layout_constraintEnd_toEndOf="parent"
app:layout_constraintTop_toTopOf="@id/guide_osm" />
<androidx.constraintlayout.widget.Barrier
android:id="@+id/barrier_osm"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
app:barrierDirection="bottom"
app:constraint_referenced_ids="label_instance_osm,current_instance_osm,button_expand_instance_osm" />
<com.google.android.material.textfield.TextInputLayout
android:id="@+id/osm_instance_container"
android:layout_width="0dp"
android:layout_height="wrap_content"
android:layout_margin="5dp"
app:layout_constraintBottom_toBottomOf="@id/barrier_osm_2"
app:layout_constraintEnd_toStartOf="@id/button_save_instance_osm"
app:layout_constraintStart_toStartOf="parent"
app:layout_constraintTop_toBottomOf="@id/barrier_osm">
<com.google.android.material.textfield.TextInputEditText
android:id="@+id/osm_instance"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:hint="@string/custom_osm"
android:inputType="textUri"
android:maxLines="1"
android:textSize="@dimen/custom_instance_input_text_size" />
</com.google.android.material.textfield.TextInputLayout>
<ImageButton
android:id="@+id/button_save_instance_osm"
android:layout_width="30dp"
android:layout_height="30dp"
android:layout_margin="5dp"
android:background="@null"
android:contentDescription="@string/save"
android:src="@drawable/ic_save"
app:layout_constraintBottom_toBottomOf="@id/barrier_osm_2"
app:layout_constraintEnd_toEndOf="parent"
app:layout_constraintTop_toTopOf="@id/barrier_osm" />
<androidx.constraintlayout.widget.Barrier
android:id="@+id/barrier_osm_2"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
app:barrierDirection="bottom"
app:constraint_referenced_ids="osm_instance_container,button_save_instance_osm" />
<CheckBox
android:id="@+id/enable_geo_uris"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_margin="5dp"
android:text="@string/use_geo_uri"
app:layout_constraintBottom_toBottomOf="parent"
app:layout_constraintTop_toBottomOf="@+id/barrier_osm_2" />
<androidx.constraintlayout.widget.Group
android:id="@+id/group_current_osm"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
app:constraint_referenced_ids="label_instance_osm,current_instance_osm,button_expand_instance_osm" />
<androidx.constraintlayout.widget.Group
android:id="@+id/group_custom_osm"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:visibility="gone"
app:constraint_referenced_ids="osm_instance_container,button_save_instance_osm" />
</androidx.constraintlayout.widget.ConstraintLayout>
</androidx.cardview.widget.CardView>
<androidx.constraintlayout.widget.ConstraintLayout
android:id="@+id/buttons_container"
style="@style/containerCard"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_gravity="center"
android:text="@string/use_geo_uri"
app:layout_constraintLeft_toLeftOf="parent"
app:layout_constraintRight_toRightOf="parent"
app:layout_constraintTop_toBottomOf="@+id/osm_instance_container" />
app:layout_constraintBottom_toTopOf="@id/list_apps"
app:layout_constraintTop_toBottomOf="@id/osm_container">
<Button
android:id="@+id/configure"
style="@style/Widget.AppCompat.Button.Colored"
android:layout_width="0dp"
android:layout_height="50dp"
android:layout_margin="5dp"
android:drawableStart="@drawable/ic_settings"
android:drawableLeft="@drawable/ic_settings"
android:drawablePadding="5dp"
android:text="@string/configure"
android:textColor="@android:color/white"
app:layout_constraintBottom_toBottomOf="parent"
app:layout_constraintEnd_toStartOf="@id/instances"
app:layout_constraintHorizontal_weight="2"
app:layout_constraintStart_toStartOf="parent"
app:layout_constraintTop_toTopOf="parent" />
<Button
android:id="@+id/button_save"
style="@style/Widget.AppCompat.Button.Colored"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginTop="5dp"
android:drawableStart="@drawable/ic_save"
android:drawableLeft="@drawable/ic_save"
android:drawablePadding="5dp"
android:minWidth="100dp"
android:text="@string/save"
android:textColor="@android:color/white"
app:layout_constraintRight_toRightOf="parent"
app:layout_constraintTop_toBottomOf="@+id/enable_geo_uris" />
<ImageButton
android:id="@+id/instances"
style="@style/Widget.AppCompat.Button.Colored"
android:layout_width="0dp"
android:layout_height="50dp"
android:layout_margin="5dp"
android:contentDescription="@string/display_supported_links"
android:src="@drawable/ic_public"
app:layout_constraintBottom_toBottomOf="parent"
app:layout_constraintEnd_toStartOf="@id/button_expand"
app:layout_constraintHorizontal_weight="1"
app:layout_constraintStart_toEndOf="@id/configure"
app:layout_constraintTop_toTopOf="parent" />
<Button
android:id="@+id/configure"
style="@style/Widget.AppCompat.Button.Colored"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginTop="10dp"
android:drawableStart="@drawable/ic_settings"
android:drawableLeft="@drawable/ic_settings"
android:drawablePadding="5dp"
android:text="@string/configure"
android:textColor="@android:color/white"
app:layout_constraintLeft_toLeftOf="parent"
app:layout_constraintRight_toLeftOf="@+id/button_expand"
app:layout_constraintTop_toBottomOf="@+id/button_save" />
<ImageButton
android:id="@+id/button_expand"
style="@style/Widget.AppCompat.Button.Colored"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginTop="10dp"
android:contentDescription="@string/display_supported_links"
android:drawableStart="@drawable/ic_save"
android:drawableLeft="@drawable/ic_save"
android:drawablePadding="5dp"
android:src="@drawable/ic_expand_more"
android:textColor="@android:color/white"
app:layout_constraintLeft_toRightOf="@+id/configure"
app:layout_constraintRight_toLeftOf="@+id/instances"
app:layout_constraintTop_toBottomOf="@+id/button_save" />
<ImageButton
android:id="@+id/instances"
style="@style/Widget.AppCompat.Button.Colored"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginTop="10dp"
android:contentDescription="@string/display_supported_links"
android:drawableStart="@drawable/ic_save"
android:drawableLeft="@drawable/ic_save"
android:drawablePadding="5dp"
android:src="@drawable/ic_public"
android:textColor="@android:color/white"
app:layout_constraintLeft_toRightOf="@+id/button_expand"
app:layout_constraintTop_toBottomOf="@+id/button_save" />
<ImageButton
android:id="@+id/button_expand"
style="@style/Widget.AppCompat.Button.Colored"
android:layout_width="0dp"
android:layout_height="50dp"
android:layout_margin="5dp"
android:contentDescription="@string/display_supported_links"
android:src="@drawable/ic_expand_more"
app:layout_constraintBottom_toBottomOf="parent"
app:layout_constraintEnd_toEndOf="parent"
app:layout_constraintHorizontal_weight="1"
app:layout_constraintStart_toEndOf="@id/instances"
app:layout_constraintTop_toTopOf="parent" />
</androidx.constraintlayout.widget.ConstraintLayout>
<androidx.recyclerview.widget.RecyclerView
android:id="@+id/list_apps"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_marginTop="20dp"
android:layout_marginBottom="20dp"
android:layout_marginTop="10dp"
android:layout_marginBottom="10dp"
android:visibility="gone"
app:layout_constraintBottom_toBottomOf="parent"
app:layout_constraintLeft_toLeftOf="parent"
app:layout_constraintRight_toRightOf="parent"
app:layout_constraintTop_toBottomOf="@+id/configure" />
app:layout_constraintTop_toBottomOf="@+id/buttons_container" />
</androidx.constraintlayout.widget.ConstraintLayout>
</ScrollView>

View File

@ -1,4 +1,5 @@
<resources>
<dimen name="about_margin">5dp</dimen>
<dimen name="fab_margin">16dp</dimen>
<dimen name="custom_instance_input_text_size">16sp</dimen>
</resources>

View File

@ -45,4 +45,5 @@
<string name="bibliogram_instances">Bibliogram instances</string>
<string name="latency">Latency</string>
<string name="error_message_internet">Check your Internet connection</string>
<string name="instance_label">Instance:</string>
</resources>

View File

@ -34,4 +34,10 @@
<item name="android:windowAnimationStyle">@android:style/Animation</item>
</style>
<style name="containerCard">
<item name="android:layout_margin">6dp</item>
<item name="cardBackgroundColor">#505050</item>
<item name="cardCornerRadius">5dp</item>
</style>
</resources>