mirror of
https://codeberg.org/gitnex/GitNex.git
synced 2025-01-05 16:12:25 +08:00
added theme selection to settings, updated login layout.
This commit is contained in:
parent
b012a7058d
commit
14addf5ed0
@ -15,13 +15,21 @@ public abstract class BaseActivity extends AppCompatActivity {
|
|||||||
@Override
|
@Override
|
||||||
public void onCreate(Bundle savedInstanceState) {
|
public void onCreate(Bundle savedInstanceState) {
|
||||||
|
|
||||||
|
final TinyDB tinyDb = new TinyDB(getApplicationContext());
|
||||||
|
|
||||||
|
if(tinyDb.getInt("themeId") == 0) {
|
||||||
|
setTheme(R.style.AppTheme);
|
||||||
|
}
|
||||||
|
else if(tinyDb.getInt("themeId") == 1) {
|
||||||
setTheme(R.style.AppThemeLight);
|
setTheme(R.style.AppThemeLight);
|
||||||
|
}
|
||||||
|
else {
|
||||||
|
setTheme(R.style.AppTheme);
|
||||||
|
}
|
||||||
|
|
||||||
super.onCreate(savedInstanceState);
|
super.onCreate(savedInstanceState);
|
||||||
setContentView(getLayoutResourceId());
|
setContentView(getLayoutResourceId());
|
||||||
|
|
||||||
final TinyDB tinyDb = new TinyDB(getApplicationContext());
|
|
||||||
|
|
||||||
if(tinyDb.getInt("customFontId") == 0) {
|
if(tinyDb.getInt("customFontId") == 0) {
|
||||||
|
|
||||||
FontsOverride.setDefaultFont(this, "DEFAULT", "fonts/roboto.ttf");
|
FontsOverride.setDefaultFont(this, "DEFAULT", "fonts/roboto.ttf");
|
||||||
|
@ -104,6 +104,7 @@ public class ReposListAdapter extends RecyclerView.Adapter<ReposListAdapter.Repo
|
|||||||
fMenuHelper.setAccessible(true);
|
fMenuHelper.setAccessible(true);
|
||||||
menuHelper = fMenuHelper.get(popupMenu);
|
menuHelper = fMenuHelper.get(popupMenu);
|
||||||
argTypes = new Class[] { boolean.class };
|
argTypes = new Class[] { boolean.class };
|
||||||
|
assert menuHelper != null;
|
||||||
menuHelper.getClass().getDeclaredMethod("setForceShowIcon",
|
menuHelper.getClass().getDeclaredMethod("setForceShowIcon",
|
||||||
argTypes).invoke(menuHelper, true);
|
argTypes).invoke(menuHelper, true);
|
||||||
|
|
||||||
|
@ -44,6 +44,9 @@ public class SettingsFragment extends Fragment {
|
|||||||
private static String[] customFontList = {"Roboto", "Manrope", "Source Code Pro"};
|
private static String[] customFontList = {"Roboto", "Manrope", "Source Code Pro"};
|
||||||
private static int customFontSelectedChoice = 0;
|
private static int customFontSelectedChoice = 0;
|
||||||
|
|
||||||
|
private static String[] themeList = {"Dark", "Light"};
|
||||||
|
private static int themeSelectedChoice = 0;
|
||||||
|
|
||||||
@Nullable
|
@Nullable
|
||||||
@Override
|
@Override
|
||||||
public View onCreateView(@NonNull LayoutInflater inflater, @Nullable ViewGroup container, @Nullable Bundle savedInstanceState) {
|
public View onCreateView(@NonNull LayoutInflater inflater, @Nullable ViewGroup container, @Nullable Bundle savedInstanceState) {
|
||||||
@ -56,12 +59,14 @@ public class SettingsFragment extends Fragment {
|
|||||||
final TextView codeBlockSelected = v.findViewById(R.id.codeBlockSelected); // setter for code block
|
final TextView codeBlockSelected = v.findViewById(R.id.codeBlockSelected); // setter for code block
|
||||||
final TextView homeScreenSelected = v.findViewById(R.id.homeScreenSelected); // setter for home screen
|
final TextView homeScreenSelected = v.findViewById(R.id.homeScreenSelected); // setter for home screen
|
||||||
final TextView customFontSelected = v.findViewById(R.id.customFontSelected); // setter for custom font
|
final TextView customFontSelected = v.findViewById(R.id.customFontSelected); // setter for custom font
|
||||||
|
final TextView themeSelected = v.findViewById(R.id.themeSelected); // setter for theme
|
||||||
|
|
||||||
LinearLayout langFrame = v.findViewById(R.id.langFrame);
|
LinearLayout langFrame = v.findViewById(R.id.langFrame);
|
||||||
LinearLayout timeFrame = v.findViewById(R.id.timeFrame);
|
LinearLayout timeFrame = v.findViewById(R.id.timeFrame);
|
||||||
LinearLayout codeBlockFrame = v.findViewById(R.id.codeBlockFrame);
|
LinearLayout codeBlockFrame = v.findViewById(R.id.codeBlockFrame);
|
||||||
LinearLayout homeScreenFrame = v.findViewById(R.id.homeScreenFrame);
|
LinearLayout homeScreenFrame = v.findViewById(R.id.homeScreenFrame);
|
||||||
LinearLayout customFontFrame = v.findViewById(R.id.customFontFrame);
|
LinearLayout customFontFrame = v.findViewById(R.id.customFontFrame);
|
||||||
|
LinearLayout themeFrame = v.findViewById(R.id.themeSelectionFrame);
|
||||||
|
|
||||||
Switch issuesSwitch = v.findViewById(R.id.switchIssuesBadge);
|
Switch issuesSwitch = v.findViewById(R.id.switchIssuesBadge);
|
||||||
TextView helpTranslate = v.findViewById(R.id.helpTranslate);
|
TextView helpTranslate = v.findViewById(R.id.helpTranslate);
|
||||||
@ -96,6 +101,10 @@ public class SettingsFragment extends Fragment {
|
|||||||
customFontSelected.setText(tinyDb.getString("customFontStr"));
|
customFontSelected.setText(tinyDb.getString("customFontStr"));
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if(!tinyDb.getString("themeStr").isEmpty()) {
|
||||||
|
themeSelected.setText(tinyDb.getString("themeStr"));
|
||||||
|
}
|
||||||
|
|
||||||
if(langSelectedChoice == 0) {
|
if(langSelectedChoice == 0) {
|
||||||
langSelectedChoice = tinyDb.getInt("langId");
|
langSelectedChoice = tinyDb.getInt("langId");
|
||||||
}
|
}
|
||||||
@ -116,6 +125,10 @@ public class SettingsFragment extends Fragment {
|
|||||||
customFontSelectedChoice = tinyDb.getInt("customFontId");
|
customFontSelectedChoice = tinyDb.getInt("customFontId");
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if(themeSelectedChoice == 0) {
|
||||||
|
themeSelectedChoice = tinyDb.getInt("themeId");
|
||||||
|
}
|
||||||
|
|
||||||
if(tinyDb.getBoolean("enableCounterIssueBadge")) {
|
if(tinyDb.getBoolean("enableCounterIssueBadge")) {
|
||||||
issuesSwitch.setChecked(true);
|
issuesSwitch.setChecked(true);
|
||||||
}
|
}
|
||||||
@ -135,6 +148,44 @@ public class SettingsFragment extends Fragment {
|
|||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
|
||||||
|
// theme selection dialog
|
||||||
|
themeFrame.setOnClickListener(new View.OnClickListener() {
|
||||||
|
@Override
|
||||||
|
public void onClick(View view) {
|
||||||
|
|
||||||
|
AlertDialog.Builder tsBuilder = new AlertDialog.Builder(ctx);
|
||||||
|
|
||||||
|
tsBuilder.setTitle(R.string.themeSelectorDialogTitle);
|
||||||
|
if(themeSelectedChoice != -1) {
|
||||||
|
tsBuilder.setCancelable(true);
|
||||||
|
}
|
||||||
|
else {
|
||||||
|
tsBuilder.setCancelable(false);
|
||||||
|
}
|
||||||
|
|
||||||
|
tsBuilder.setSingleChoiceItems(themeList, themeSelectedChoice, new DialogInterface.OnClickListener() {
|
||||||
|
@Override
|
||||||
|
public void onClick(DialogInterface dialogInterfaceTheme, int i) {
|
||||||
|
|
||||||
|
themeSelectedChoice = i;
|
||||||
|
themeSelected.setText(themeList[i]);
|
||||||
|
tinyDb.putString("themeStr", themeList[i]);
|
||||||
|
tinyDb.putInt("themeId", i);
|
||||||
|
|
||||||
|
Objects.requireNonNull(getActivity()).recreate();
|
||||||
|
getActivity().overridePendingTransition(0, 0);
|
||||||
|
dialogInterfaceTheme.dismiss();
|
||||||
|
Toasty.info(getContext(), getResources().getString(R.string.settingsSave));
|
||||||
|
|
||||||
|
}
|
||||||
|
});
|
||||||
|
|
||||||
|
AlertDialog cfDialog = tsBuilder.create();
|
||||||
|
cfDialog.show();
|
||||||
|
|
||||||
|
}
|
||||||
|
});
|
||||||
|
|
||||||
// custom font dialog
|
// custom font dialog
|
||||||
customFontFrame.setOnClickListener(new View.OnClickListener() {
|
customFontFrame.setOnClickListener(new View.OnClickListener() {
|
||||||
@Override
|
@Override
|
||||||
|
5
app/src/main/res/drawable/ic_arrow_back_24dp.xml
Normal file
5
app/src/main/res/drawable/ic_arrow_back_24dp.xml
Normal file
@ -0,0 +1,5 @@
|
|||||||
|
<vector android:autoMirrored="true" android:height="24dp"
|
||||||
|
android:tint="#368F73" android:viewportHeight="24.0"
|
||||||
|
android:viewportWidth="24.0" android:width="24dp" xmlns:android="http://schemas.android.com/apk/res/android">
|
||||||
|
<path android:fillColor="#FF000000" android:pathData="M20,11H7.83l5.59,-5.59L12,4l-8,8 8,8 1.41,-1.41L7.83,13H20v-2z"/>
|
||||||
|
</vector>
|
@ -64,30 +64,35 @@
|
|||||||
|
|
||||||
</RadioGroup>
|
</RadioGroup>
|
||||||
|
|
||||||
<LinearLayout
|
<RelativeLayout
|
||||||
android:layout_width="match_parent"
|
android:layout_width="wrap_content"
|
||||||
android:layout_height="wrap_content">
|
android:layout_height="wrap_content"
|
||||||
|
android:background="@drawable/shape_dropdown"
|
||||||
|
android:layout_marginStart="10dp"
|
||||||
|
android:layout_marginTop="10dp"
|
||||||
|
android:layout_marginBottom="10dp" >
|
||||||
|
|
||||||
<Spinner
|
<Spinner
|
||||||
android:id="@+id/httpsSpinner"
|
android:id="@+id/httpsSpinner"
|
||||||
android:layout_width="120dp"
|
android:layout_width="120dp"
|
||||||
android:layout_height="44dp"
|
android:layout_height="44dp"
|
||||||
android:dropDownWidth="120dp"
|
android:spinnerMode="dropdown"
|
||||||
android:background="@drawable/spinner"
|
android:padding="10dp" />
|
||||||
android:layout_marginStart="10dp"
|
|
||||||
android:layout_marginTop="10dp"
|
</RelativeLayout>
|
||||||
android:layout_marginBottom="10dp"
|
|
||||||
android:paddingStart="10dp"
|
<LinearLayout
|
||||||
android:paddingEnd="10dp"
|
android:visibility="gone"
|
||||||
android:paddingTop="10dp" />
|
android:layout_width="wrap_content"
|
||||||
|
android:layout_height="wrap_content">
|
||||||
|
|
||||||
<ImageView
|
<ImageView
|
||||||
android:id="@+id/info"
|
android:id="@+id/info"
|
||||||
android:layout_width="28dp"
|
android:layout_width="28dp"
|
||||||
android:layout_height="28dp"
|
android:layout_height="28dp"
|
||||||
android:src="@drawable/ic_info_24dp"
|
android:src="@drawable/ic_info_24dp"
|
||||||
android:layout_marginStart="20dp"
|
android:layout_marginStart="120dp"
|
||||||
android:layout_marginTop="15dp"
|
android:layout_marginTop="10dp"
|
||||||
android:contentDescription="@string/urlInfoTooltip"
|
android:contentDescription="@string/urlInfoTooltip"
|
||||||
/>
|
/>
|
||||||
|
|
||||||
@ -106,8 +111,8 @@
|
|||||||
android:inputType="textUri"
|
android:inputType="textUri"
|
||||||
android:background="@drawable/shape_inputs"
|
android:background="@drawable/shape_inputs"
|
||||||
android:textColor="?attr/inputTextColor"
|
android:textColor="?attr/inputTextColor"
|
||||||
android:textColorHint="?attr/primaryBackgroundColor"
|
android:textColorHint="?attr/hintColor"
|
||||||
android:textColorHighlight="?attr/primaryTextColor"
|
android:textColorHighlight="?attr/hintColor"
|
||||||
android:hint="@string/instanceUrl" />
|
android:hint="@string/instanceUrl" />
|
||||||
|
|
||||||
<EditText
|
<EditText
|
||||||
@ -122,8 +127,8 @@
|
|||||||
android:drawablePadding="10dp"
|
android:drawablePadding="10dp"
|
||||||
android:background="@drawable/shape_inputs"
|
android:background="@drawable/shape_inputs"
|
||||||
android:textColor="?attr/inputTextColor"
|
android:textColor="?attr/inputTextColor"
|
||||||
android:textColorHint="?attr/primaryBackgroundColor"
|
android:textColorHint="?attr/hintColor"
|
||||||
android:textColorHighlight="?attr/primaryTextColor"
|
android:textColorHighlight="?attr/hintColor"
|
||||||
android:hint="@string/userName"
|
android:hint="@string/userName"
|
||||||
android:inputType="text" />
|
android:inputType="text" />
|
||||||
|
|
||||||
@ -139,8 +144,8 @@
|
|||||||
android:drawablePadding="10dp"
|
android:drawablePadding="10dp"
|
||||||
android:background="@drawable/shape_inputs"
|
android:background="@drawable/shape_inputs"
|
||||||
android:textColor="?attr/inputTextColor"
|
android:textColor="?attr/inputTextColor"
|
||||||
android:textColorHint="?attr/primaryBackgroundColor"
|
android:textColorHint="?attr/hintColor"
|
||||||
android:textColorHighlight="?attr/primaryTextColor"
|
android:textColorHighlight="?attr/hintColor"
|
||||||
android:hint="@string/passWord"
|
android:hint="@string/passWord"
|
||||||
android:inputType="textPassword" />
|
android:inputType="textPassword" />
|
||||||
|
|
||||||
@ -156,8 +161,8 @@
|
|||||||
android:drawablePadding="10dp"
|
android:drawablePadding="10dp"
|
||||||
android:background="@drawable/shape_inputs"
|
android:background="@drawable/shape_inputs"
|
||||||
android:textColor="?attr/inputTextColor"
|
android:textColor="?attr/inputTextColor"
|
||||||
android:textColorHint="?attr/primaryBackgroundColor"
|
android:textColorHint="?attr/hintColor"
|
||||||
android:textColorHighlight="?attr/primaryTextColor"
|
android:textColorHighlight="?attr/hintColor"
|
||||||
android:hint="@string/loginOTP"
|
android:hint="@string/loginOTP"
|
||||||
android:inputType="number" />
|
android:inputType="number" />
|
||||||
|
|
||||||
@ -173,8 +178,8 @@
|
|||||||
android:drawablePadding="10dp"
|
android:drawablePadding="10dp"
|
||||||
android:background="@drawable/shape_inputs"
|
android:background="@drawable/shape_inputs"
|
||||||
android:textColor="?attr/inputTextColor"
|
android:textColor="?attr/inputTextColor"
|
||||||
android:textColorHint="?attr/primaryBackgroundColor"
|
android:textColorHint="?attr/hintColor"
|
||||||
android:textColorHighlight="?attr/primaryTextColor"
|
android:textColorHighlight="?attr/hintColor"
|
||||||
android:hint="@string/copyToken"
|
android:hint="@string/copyToken"
|
||||||
android:inputType="text"
|
android:inputType="text"
|
||||||
android:visibility="gone" />
|
android:visibility="gone" />
|
||||||
|
@ -13,7 +13,6 @@
|
|||||||
android:id="@+id/appbar"
|
android:id="@+id/appbar"
|
||||||
android:layout_width="match_parent"
|
android:layout_width="match_parent"
|
||||||
android:layout_height="wrap_content"
|
android:layout_height="wrap_content"
|
||||||
android:paddingTop="@dimen/appbar_padding_top"
|
|
||||||
android:theme="@style/AppTheme.AppBarOverlay">
|
android:theme="@style/AppTheme.AppBarOverlay">
|
||||||
|
|
||||||
<androidx.appcompat.widget.Toolbar
|
<androidx.appcompat.widget.Toolbar
|
||||||
@ -42,6 +41,7 @@
|
|||||||
app:tabTextAppearance="@style/customTabLayout"
|
app:tabTextAppearance="@style/customTabLayout"
|
||||||
app:tabMode="scrollable"
|
app:tabMode="scrollable"
|
||||||
app:tabTextColor="?attr/primaryTextColor"
|
app:tabTextColor="?attr/primaryTextColor"
|
||||||
|
android:background="?attr/primaryBackgroundColor"
|
||||||
android:layout_width="match_parent"
|
android:layout_width="match_parent"
|
||||||
android:layout_height="wrap_content">
|
android:layout_height="wrap_content">
|
||||||
|
|
||||||
|
@ -13,7 +13,6 @@
|
|||||||
android:id="@+id/appbar"
|
android:id="@+id/appbar"
|
||||||
android:layout_width="match_parent"
|
android:layout_width="match_parent"
|
||||||
android:layout_height="wrap_content"
|
android:layout_height="wrap_content"
|
||||||
android:paddingTop="@dimen/appbar_padding_top"
|
|
||||||
android:theme="@style/AppTheme.AppBarOverlay">
|
android:theme="@style/AppTheme.AppBarOverlay">
|
||||||
|
|
||||||
<androidx.appcompat.widget.Toolbar
|
<androidx.appcompat.widget.Toolbar
|
||||||
|
@ -80,6 +80,7 @@
|
|||||||
app:tabTextAppearance="@style/customTabLayout"
|
app:tabTextAppearance="@style/customTabLayout"
|
||||||
android:layout_width="match_parent"
|
android:layout_width="match_parent"
|
||||||
app:tabTextColor="?attr/primaryTextColor"
|
app:tabTextColor="?attr/primaryTextColor"
|
||||||
|
android:background="?attr/primaryBackgroundColor"
|
||||||
android:layout_height="wrap_content">
|
android:layout_height="wrap_content">
|
||||||
|
|
||||||
<com.google.android.material.tabs.TabItem
|
<com.google.android.material.tabs.TabItem
|
||||||
|
@ -17,6 +17,66 @@
|
|||||||
android:textStyle="bold"
|
android:textStyle="bold"
|
||||||
android:textColor="@color/colorDarkGreen"/>
|
android:textColor="@color/colorDarkGreen"/>
|
||||||
|
|
||||||
|
<LinearLayout
|
||||||
|
android:id="@+id/themeSelectionFrame"
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:layout_marginTop="10dp"
|
||||||
|
android:orientation="vertical">
|
||||||
|
|
||||||
|
<TextView
|
||||||
|
android:id="@+id/themeHeaderSelector"
|
||||||
|
android:layout_width="wrap_content"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:textSize="16sp"
|
||||||
|
android:layout_marginTop="10dp"
|
||||||
|
android:layout_marginStart="44dp"
|
||||||
|
android:layout_marginEnd="4dp"
|
||||||
|
android:text="@string/themeSelectionHeaderText"
|
||||||
|
android:textColor="?attr/primaryTextColor"/>
|
||||||
|
|
||||||
|
<TextView
|
||||||
|
android:id="@+id/themeSelected"
|
||||||
|
android:layout_width="wrap_content"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:textSize="14sp"
|
||||||
|
android:layout_marginStart="44dp"
|
||||||
|
android:layout_marginEnd="4dp"
|
||||||
|
android:text="@string/themeSelectionSelectedText"
|
||||||
|
android:textColor="?attr/selectedTextColor"/>
|
||||||
|
|
||||||
|
</LinearLayout>
|
||||||
|
|
||||||
|
<LinearLayout
|
||||||
|
android:id="@+id/customFontFrame"
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:layout_marginTop="10dp"
|
||||||
|
android:orientation="vertical">
|
||||||
|
|
||||||
|
<TextView
|
||||||
|
android:id="@+id/customFontHeaderSelector"
|
||||||
|
android:layout_width="wrap_content"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:textSize="16sp"
|
||||||
|
android:layout_marginTop="10dp"
|
||||||
|
android:layout_marginStart="44dp"
|
||||||
|
android:layout_marginEnd="4dp"
|
||||||
|
android:text="@string/settingsCustomFontHeaderText"
|
||||||
|
android:textColor="?attr/primaryTextColor"/>
|
||||||
|
|
||||||
|
<TextView
|
||||||
|
android:id="@+id/customFontSelected"
|
||||||
|
android:layout_width="wrap_content"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:textSize="14sp"
|
||||||
|
android:layout_marginStart="44dp"
|
||||||
|
android:layout_marginEnd="4dp"
|
||||||
|
android:text="@string/defaultCopy"
|
||||||
|
android:textColor="?attr/selectedTextColor"/>
|
||||||
|
|
||||||
|
</LinearLayout>
|
||||||
|
|
||||||
<LinearLayout
|
<LinearLayout
|
||||||
android:id="@+id/timeFrame"
|
android:id="@+id/timeFrame"
|
||||||
android:layout_width="match_parent"
|
android:layout_width="match_parent"
|
||||||
@ -136,34 +196,4 @@
|
|||||||
|
|
||||||
</LinearLayout>
|
</LinearLayout>
|
||||||
|
|
||||||
<LinearLayout
|
|
||||||
android:id="@+id/customFontFrame"
|
|
||||||
android:layout_width="match_parent"
|
|
||||||
android:layout_height="wrap_content"
|
|
||||||
android:layout_marginTop="10dp"
|
|
||||||
android:orientation="vertical">
|
|
||||||
|
|
||||||
<TextView
|
|
||||||
android:id="@+id/customFontHeaderSelector"
|
|
||||||
android:layout_width="wrap_content"
|
|
||||||
android:layout_height="wrap_content"
|
|
||||||
android:textSize="16sp"
|
|
||||||
android:layout_marginTop="10dp"
|
|
||||||
android:layout_marginStart="44dp"
|
|
||||||
android:layout_marginEnd="4dp"
|
|
||||||
android:text="@string/settingsCustomFontHeaderText"
|
|
||||||
android:textColor="?attr/primaryTextColor"/>
|
|
||||||
|
|
||||||
<TextView
|
|
||||||
android:id="@+id/customFontSelected"
|
|
||||||
android:layout_width="wrap_content"
|
|
||||||
android:layout_height="wrap_content"
|
|
||||||
android:textSize="14sp"
|
|
||||||
android:layout_marginStart="44dp"
|
|
||||||
android:layout_marginEnd="4dp"
|
|
||||||
android:text="@string/defaultCopy"
|
|
||||||
android:textColor="?attr/selectedTextColor"/>
|
|
||||||
|
|
||||||
</LinearLayout>
|
|
||||||
|
|
||||||
</LinearLayout>
|
</LinearLayout>
|
@ -3,6 +3,7 @@
|
|||||||
<attr name="primaryTextColor" format="reference"/>
|
<attr name="primaryTextColor" format="reference"/>
|
||||||
<attr name="primaryBackgroundColor" format="reference" />
|
<attr name="primaryBackgroundColor" format="reference" />
|
||||||
<attr name="inputBackgroundColor" format="reference" />
|
<attr name="inputBackgroundColor" format="reference" />
|
||||||
|
<attr name="hintColor" format="reference" />
|
||||||
<attr name="inputTextColor" format="reference" />
|
<attr name="inputTextColor" format="reference" />
|
||||||
<attr name="selectedTextColor" format="reference" />
|
<attr name="selectedTextColor" format="reference" />
|
||||||
<attr name="alertDialogTheme" format="reference" />
|
<attr name="alertDialogTheme" format="reference" />
|
||||||
|
@ -259,6 +259,12 @@
|
|||||||
<string name="settingsHomeScreenHeaderText">Home Screen</string>
|
<string name="settingsHomeScreenHeaderText">Home Screen</string>
|
||||||
<string name="settingsHomeScreenSelectedText">My Repositories</string>
|
<string name="settingsHomeScreenSelectedText">My Repositories</string>
|
||||||
<string name="settingshomeScreenSelectorDialogTitle">Select Home Screen</string>
|
<string name="settingshomeScreenSelectorDialogTitle">Select Home Screen</string>
|
||||||
|
<string name="settingsCustomFontHeaderText">Font</string>
|
||||||
|
<string name="settingsCustomFontSelectorDialogTitle">Choose Font</string>
|
||||||
|
<string name="settingsCustomFontDefault">Roboto</string>
|
||||||
|
<string name="themeSelectorDialogTitle">Select App Theme</string>
|
||||||
|
<string name="themeSelectionHeaderText">Theme</string>
|
||||||
|
<string name="themeSelectionSelectedText" translatable="false">Dark</string>
|
||||||
<!-- settings -->
|
<!-- settings -->
|
||||||
|
|
||||||
<string name="noMoreData">No more data available</string>
|
<string name="noMoreData">No more data available</string>
|
||||||
@ -543,8 +549,4 @@
|
|||||||
<string name="mergePRSuccessMsg">Pull Request was merged successfully</string>
|
<string name="mergePRSuccessMsg">Pull Request was merged successfully</string>
|
||||||
<string name="mergePR404ErrorMsg">Pull Request is not available for merge</string>
|
<string name="mergePR404ErrorMsg">Pull Request is not available for merge</string>
|
||||||
|
|
||||||
<string name="settingsCustomFontHeaderText">Font</string>
|
|
||||||
<string name="settingsCustomFontSelectorDialogTitle">Choose Font</string>
|
|
||||||
<string name="settingsCustomFontDefault">Roboto</string>
|
|
||||||
|
|
||||||
</resources>
|
</resources>
|
||||||
|
@ -14,8 +14,11 @@
|
|||||||
<item name="inputTextColor">@color/colorWhite</item>
|
<item name="inputTextColor">@color/colorWhite</item>
|
||||||
<item name="checkboxStyle">@style/AppThemeCheckBoxStyle</item>
|
<item name="checkboxStyle">@style/AppThemeCheckBoxStyle</item>
|
||||||
<item name="selectedTextColor">@color/darkGreen</item>
|
<item name="selectedTextColor">@color/darkGreen</item>
|
||||||
<item name="dialogTheme">@style/AppThemeConfirmDialog</item>
|
<item name="alertDialogTheme">@style/AppThemeConfirmDialog</item>
|
||||||
<item name="popupMenuStyle">@style/AppThemePopupMenuStyle</item>
|
<item name="popupMenuStyle">@style/AppThemePopupMenuStyle</item>
|
||||||
|
<item name="android:homeAsUpIndicator">@drawable/ic_arrow_back_24dp</item>
|
||||||
|
<item name="autoCompleteTextViewStyle">@style/AppThemeDarkSearchAutoCompleteTextView</item>
|
||||||
|
<item name="hintColor">@color/hintColor</item>
|
||||||
</style>
|
</style>
|
||||||
<!-- Dark theme - default -->
|
<!-- Dark theme - default -->
|
||||||
|
|
||||||
@ -32,41 +35,51 @@
|
|||||||
<item name="inputTextColor">@color/lightThemeInputTextColor</item>
|
<item name="inputTextColor">@color/lightThemeInputTextColor</item>
|
||||||
<item name="checkboxStyle">@style/AppThemeLightCheckBoxStyle</item>
|
<item name="checkboxStyle">@style/AppThemeLightCheckBoxStyle</item>
|
||||||
<item name="selectedTextColor">@color/darkGreen</item>
|
<item name="selectedTextColor">@color/darkGreen</item>
|
||||||
<item name="dialogTheme">@style/AppThemeLightConfirmDialog</item>
|
<item name="alertDialogTheme">@style/AppThemeLightConfirmDialog</item>
|
||||||
<item name="popupMenuStyle">@style/AppThemePopupMenuStyle</item>
|
<item name="popupMenuStyle">@style/AppThemeLightPopupMenuStyle</item>
|
||||||
|
<item name="android:homeAsUpIndicator">@drawable/ic_arrow_back_24dp</item>
|
||||||
|
<item name="autoCompleteTextViewStyle">@style/AppThemeLightSearchAutoCompleteTextView</item>
|
||||||
|
<item name="hintColor">@color/hintColor</item>
|
||||||
</style>
|
</style>
|
||||||
<!-- Light theme -->
|
<!-- Light theme -->
|
||||||
|
|
||||||
|
<style name="AppThemeLightSearchAutoCompleteTextView" parent="Widget.AppCompat.Light.AutoCompleteTextView">
|
||||||
|
<item name="android:textColor">@color/lightThemeTextColor</item>
|
||||||
|
<item name="android:textColorHint">@color/lightThemeTextColor</item>
|
||||||
|
</style>
|
||||||
|
|
||||||
|
<style name="AppThemeDarkSearchAutoCompleteTextView" parent="Widget.AppCompat.Light.AutoCompleteTextView">
|
||||||
|
<item name="android:textColor">@color/colorWhite</item>
|
||||||
|
<item name="android:textColorHint">@color/colorWhite</item>
|
||||||
|
</style>
|
||||||
|
|
||||||
<style name="AppThemeConfirmDialog" parent="Theme.AppCompat.Dialog.Alert">
|
<style name="AppThemeConfirmDialog" parent="Theme.AppCompat.Dialog.Alert">
|
||||||
<item name="android:background">@color/colorPrimary</item>
|
<item name="android:background">@color/colorPrimary</item>
|
||||||
<item name="android:textColorPrimary">@android:color/white</item>
|
<item name="android:textColorPrimary">@color/white</item>
|
||||||
<item name="android:textColor">@android:color/white</item>
|
<item name="android:textColor">@color/white</item>
|
||||||
<item name="colorControlNormal">@color/white</item>
|
<item name="colorControlNormal">@color/white</item>
|
||||||
<item name="colorControlActivated">@color/white</item>
|
<item name="colorControlActivated">@color/darkGreen</item>
|
||||||
</style>
|
</style>
|
||||||
|
|
||||||
<style name="AppThemeLightConfirmDialog" parent="Theme.AppCompat.Dialog.Alert">
|
<style name="AppThemeLightConfirmDialog" parent="Theme.AppCompat.Light.Dialog.Alert">
|
||||||
<item name="android:background">@color/colorPrimary</item>
|
<item name="android:background">@color/white</item>
|
||||||
<item name="android:textColorPrimary">@color/colorPrimary</item>
|
<item name="android:textColorPrimary">@color/lightThemeTextColor</item>
|
||||||
<item name="android:textColor">@color/lightThemeTextColor</item>
|
<item name="android:textColor">@color/lightThemeTextColor</item>
|
||||||
<item name="colorControlNormal">@color/lightThemeTextColor</item>
|
<item name="colorControlNormal">@color/lightThemeTextColor</item>
|
||||||
<item name="colorControlActivated">@color/lightThemeTextColor</item>
|
<item name="colorControlActivated">@color/darkGreen</item>
|
||||||
</style>
|
</style>
|
||||||
|
|
||||||
<style name="AppThemePopupMenuStyle">
|
<style name="AppThemePopupMenuStyle" parent="Widget.AppCompat.PopupMenu">
|
||||||
<item name="android:itemBackground">@color/colorPrimary</item>
|
<item name="android:popupBackground">@color/colorPrimary</item>
|
||||||
<item name="android:background">@android:color/transparent</item>
|
<item name="android:textColor">@color/white</item>
|
||||||
<item name="android:textColor">@android:color/white</item>
|
|
||||||
<item name="android:colorBackground">@color/colorPrimary</item>
|
|
||||||
<item name="android:layout_marginStart">3dp</item>
|
<item name="android:layout_marginStart">3dp</item>
|
||||||
<item name="android:layout_marginEnd">3dp</item>
|
<item name="android:layout_marginEnd">3dp</item>
|
||||||
</style>
|
</style>
|
||||||
|
|
||||||
<style name="AppThemeLightPopupMenuStyle">
|
<style name="AppThemeLightPopupMenuStyle" parent="Widget.AppCompat.Light.PopupMenu">
|
||||||
|
<item name="android:popupBackground">@color/white</item>
|
||||||
<item name="android:itemBackground">@color/lightThemeBackground</item>
|
<item name="android:itemBackground">@color/lightThemeBackground</item>
|
||||||
<item name="android:background">@android:color/transparent</item>
|
|
||||||
<item name="android:textColor">@color/lightThemeTextColor</item>
|
<item name="android:textColor">@color/lightThemeTextColor</item>
|
||||||
<item name="android:colorBackground">@color/lightThemeBackground</item>
|
|
||||||
<item name="android:layout_marginStart">3dp</item>
|
<item name="android:layout_marginStart">3dp</item>
|
||||||
<item name="android:layout_marginEnd">3dp</item>
|
<item name="android:layout_marginEnd">3dp</item>
|
||||||
</style>
|
</style>
|
||||||
|
Loading…
Reference in New Issue
Block a user