mirror of
https://codeberg.org/gitnex/GitNex.git
synced 2024-12-16 15:48:13 +08:00
Added custom attr to more files
This commit is contained in:
parent
acdb9ce682
commit
1008b8611d
@ -15,7 +15,7 @@ public abstract class BaseActivity extends AppCompatActivity {
|
|||||||
@Override
|
@Override
|
||||||
public void onCreate(Bundle savedInstanceState) {
|
public void onCreate(Bundle savedInstanceState) {
|
||||||
|
|
||||||
setTheme(R.style.AppTheme);
|
setTheme(R.style.AppThemeLight);
|
||||||
|
|
||||||
super.onCreate(savedInstanceState);
|
super.onCreate(savedInstanceState);
|
||||||
setContentView(getLayoutResourceId());
|
setContentView(getLayoutResourceId());
|
||||||
|
@ -410,7 +410,7 @@ public class MainActivity extends BaseActivity implements NavigationView.OnNavig
|
|||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public void onFailure(@NonNull Call<GiteaVersion> callVersion, Throwable t) {
|
public void onFailure(@NonNull Call<GiteaVersion> callVersion, @NonNull Throwable t) {
|
||||||
|
|
||||||
Log.e("onFailure-version", t.toString());
|
Log.e("onFailure-version", t.toString());
|
||||||
|
|
||||||
|
@ -2,7 +2,6 @@ package org.mian.gitnex.activities;
|
|||||||
|
|
||||||
import android.os.Bundle;
|
import android.os.Bundle;
|
||||||
import androidx.annotation.Nullable;
|
import androidx.annotation.Nullable;
|
||||||
import androidx.appcompat.app.AppCompatActivity;
|
|
||||||
import androidx.lifecycle.Observer;
|
import androidx.lifecycle.Observer;
|
||||||
import androidx.lifecycle.ViewModelProvider;
|
import androidx.lifecycle.ViewModelProvider;
|
||||||
import android.view.View;
|
import android.view.View;
|
||||||
@ -22,7 +21,7 @@ import java.util.List;
|
|||||||
* Author M M Arif
|
* Author M M Arif
|
||||||
*/
|
*/
|
||||||
|
|
||||||
public class RepoStargazersActivity extends AppCompatActivity {
|
public class RepoStargazersActivity extends BaseActivity {
|
||||||
|
|
||||||
private TextView noDataStargazers;
|
private TextView noDataStargazers;
|
||||||
private View.OnClickListener onClickListener;
|
private View.OnClickListener onClickListener;
|
||||||
@ -31,9 +30,13 @@ public class RepoStargazersActivity extends AppCompatActivity {
|
|||||||
private ProgressBar mProgressBar;
|
private ProgressBar mProgressBar;
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
protected void onCreate(Bundle savedInstanceState) {
|
protected int getLayoutResourceId(){
|
||||||
|
return R.layout.activity_repo_stargazers;
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public void onCreate(Bundle savedInstanceState) {
|
||||||
super.onCreate(savedInstanceState);
|
super.onCreate(savedInstanceState);
|
||||||
setContentView(R.layout.activity_repo_stargazers);
|
|
||||||
|
|
||||||
TinyDB tinyDb = new TinyDB(getApplicationContext());
|
TinyDB tinyDb = new TinyDB(getApplicationContext());
|
||||||
final String instanceUrl = tinyDb.getString("instanceUrl");
|
final String instanceUrl = tinyDb.getString("instanceUrl");
|
||||||
|
@ -2,7 +2,6 @@ package org.mian.gitnex.activities;
|
|||||||
|
|
||||||
import android.os.Bundle;
|
import android.os.Bundle;
|
||||||
import androidx.annotation.Nullable;
|
import androidx.annotation.Nullable;
|
||||||
import androidx.appcompat.app.AppCompatActivity;
|
|
||||||
import androidx.lifecycle.Observer;
|
import androidx.lifecycle.Observer;
|
||||||
import androidx.lifecycle.ViewModelProvider;
|
import androidx.lifecycle.ViewModelProvider;
|
||||||
import android.view.View;
|
import android.view.View;
|
||||||
@ -22,7 +21,7 @@ import java.util.List;
|
|||||||
* Author M M Arif
|
* Author M M Arif
|
||||||
*/
|
*/
|
||||||
|
|
||||||
public class RepoWatchersActivity extends AppCompatActivity {
|
public class RepoWatchersActivity extends BaseActivity {
|
||||||
|
|
||||||
private TextView noDataWatchers;
|
private TextView noDataWatchers;
|
||||||
private View.OnClickListener onClickListener;
|
private View.OnClickListener onClickListener;
|
||||||
@ -31,9 +30,13 @@ public class RepoWatchersActivity extends AppCompatActivity {
|
|||||||
private ProgressBar mProgressBar;
|
private ProgressBar mProgressBar;
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
protected void onCreate(Bundle savedInstanceState) {
|
protected int getLayoutResourceId(){
|
||||||
|
return R.layout.activity_repo_watchers;
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public void onCreate(Bundle savedInstanceState) {
|
||||||
super.onCreate(savedInstanceState);
|
super.onCreate(savedInstanceState);
|
||||||
setContentView(R.layout.activity_repo_watchers);
|
|
||||||
|
|
||||||
TinyDB tinyDb = new TinyDB(getApplicationContext());
|
TinyDB tinyDb = new TinyDB(getApplicationContext());
|
||||||
final String instanceUrl = tinyDb.getString("instanceUrl");
|
final String instanceUrl = tinyDb.getString("instanceUrl");
|
||||||
|
@ -25,7 +25,7 @@ public class RepoStargazersAdapter extends BaseAdapter {
|
|||||||
private List<UserInfo> stargazersList;
|
private List<UserInfo> stargazersList;
|
||||||
private Context mCtx;
|
private Context mCtx;
|
||||||
|
|
||||||
private class ViewHolder {
|
private static class ViewHolder {
|
||||||
|
|
||||||
private ImageView memberAvatar;
|
private ImageView memberAvatar;
|
||||||
private TextView memberName;
|
private TextView memberName;
|
||||||
@ -64,7 +64,7 @@ public class RepoStargazersAdapter extends BaseAdapter {
|
|||||||
|
|
||||||
if (finalView == null) {
|
if (finalView == null) {
|
||||||
finalView = LayoutInflater.from(mCtx).inflate(R.layout.repo_stargazers_list, null);
|
finalView = LayoutInflater.from(mCtx).inflate(R.layout.repo_stargazers_list, null);
|
||||||
viewHolder = new RepoStargazersAdapter.ViewHolder(finalView);
|
viewHolder = new ViewHolder(finalView);
|
||||||
finalView.setTag(viewHolder);
|
finalView.setTag(viewHolder);
|
||||||
}
|
}
|
||||||
else {
|
else {
|
||||||
|
@ -25,7 +25,7 @@ public class RepoWatchersAdapter extends BaseAdapter {
|
|||||||
private List<UserInfo> watchersList;
|
private List<UserInfo> watchersList;
|
||||||
private Context mCtx;
|
private Context mCtx;
|
||||||
|
|
||||||
private class ViewHolder {
|
private static class ViewHolder {
|
||||||
|
|
||||||
private ImageView memberAvatar;
|
private ImageView memberAvatar;
|
||||||
private TextView memberName;
|
private TextView memberName;
|
||||||
@ -64,7 +64,7 @@ public class RepoWatchersAdapter extends BaseAdapter {
|
|||||||
|
|
||||||
if (finalView == null) {
|
if (finalView == null) {
|
||||||
finalView = LayoutInflater.from(mCtx).inflate(R.layout.repo_watchers_list, null);
|
finalView = LayoutInflater.from(mCtx).inflate(R.layout.repo_watchers_list, null);
|
||||||
viewHolder = new RepoWatchersAdapter.ViewHolder(finalView);
|
viewHolder = new ViewHolder(finalView);
|
||||||
finalView.setTag(viewHolder);
|
finalView.setTag(viewHolder);
|
||||||
}
|
}
|
||||||
else {
|
else {
|
||||||
|
@ -140,7 +140,7 @@ public class SettingsFragment extends Fragment {
|
|||||||
@Override
|
@Override
|
||||||
public void onClick(View view) {
|
public void onClick(View view) {
|
||||||
|
|
||||||
AlertDialog.Builder cfBuilder = new AlertDialog.Builder(ctx, R.style.AppThemeLightConfirmDialog);
|
AlertDialog.Builder cfBuilder = new AlertDialog.Builder(ctx);
|
||||||
|
|
||||||
cfBuilder.setTitle(R.string.settingsCustomFontSelectorDialogTitle);
|
cfBuilder.setTitle(R.string.settingsCustomFontSelectorDialogTitle);
|
||||||
if(customFontSelectedChoice != -1) {
|
if(customFontSelectedChoice != -1) {
|
||||||
|
@ -3,7 +3,7 @@
|
|||||||
xmlns:tools="http://schemas.android.com/tools"
|
xmlns:tools="http://schemas.android.com/tools"
|
||||||
android:layout_width="match_parent"
|
android:layout_width="match_parent"
|
||||||
android:layout_height="match_parent"
|
android:layout_height="match_parent"
|
||||||
android:background="@color/colorPrimary"
|
android:background="?attr/primaryBackgroundColor"
|
||||||
android:orientation="vertical">
|
android:orientation="vertical">
|
||||||
|
|
||||||
<com.google.android.material.appbar.AppBarLayout
|
<com.google.android.material.appbar.AppBarLayout
|
||||||
@ -14,7 +14,7 @@
|
|||||||
android:id="@+id/toolbar"
|
android:id="@+id/toolbar"
|
||||||
android:layout_width="match_parent"
|
android:layout_width="match_parent"
|
||||||
android:layout_height="wrap_content"
|
android:layout_height="wrap_content"
|
||||||
android:background="?attr/colorPrimary"
|
android:background="?attr/primaryBackgroundColor"
|
||||||
tools:ignore="UnusedAttribute">
|
tools:ignore="UnusedAttribute">
|
||||||
|
|
||||||
<ImageView
|
<ImageView
|
||||||
@ -32,7 +32,7 @@
|
|||||||
android:layout_width="match_parent"
|
android:layout_width="match_parent"
|
||||||
android:layout_height="wrap_content"
|
android:layout_height="wrap_content"
|
||||||
android:layout_gravity="center_vertical"
|
android:layout_gravity="center_vertical"
|
||||||
android:textColor="@color/white"
|
android:textColor="?attr/primaryTextColor"
|
||||||
android:maxLines="1"
|
android:maxLines="1"
|
||||||
android:textSize="20sp" />
|
android:textSize="20sp" />
|
||||||
|
|
||||||
@ -58,7 +58,7 @@
|
|||||||
android:layout_margin="15dp"
|
android:layout_margin="15dp"
|
||||||
android:gravity="center"
|
android:gravity="center"
|
||||||
android:text="@string/noDataFound"
|
android:text="@string/noDataFound"
|
||||||
android:textColor="@color/white"
|
android:textColor="?attr/primaryTextColor"
|
||||||
android:textSize="20sp"
|
android:textSize="20sp"
|
||||||
android:visibility="gone" />
|
android:visibility="gone" />
|
||||||
|
|
||||||
|
@ -3,7 +3,7 @@
|
|||||||
xmlns:tools="http://schemas.android.com/tools"
|
xmlns:tools="http://schemas.android.com/tools"
|
||||||
android:layout_width="match_parent"
|
android:layout_width="match_parent"
|
||||||
android:layout_height="match_parent"
|
android:layout_height="match_parent"
|
||||||
android:background="@color/colorPrimary"
|
android:background="?attr/primaryBackgroundColor"
|
||||||
android:orientation="vertical">
|
android:orientation="vertical">
|
||||||
|
|
||||||
<com.google.android.material.appbar.AppBarLayout
|
<com.google.android.material.appbar.AppBarLayout
|
||||||
@ -14,7 +14,7 @@
|
|||||||
android:id="@+id/toolbar"
|
android:id="@+id/toolbar"
|
||||||
android:layout_width="match_parent"
|
android:layout_width="match_parent"
|
||||||
android:layout_height="wrap_content"
|
android:layout_height="wrap_content"
|
||||||
android:background="?attr/colorPrimary"
|
android:background="?attr/primaryBackgroundColor"
|
||||||
tools:ignore="UnusedAttribute">
|
tools:ignore="UnusedAttribute">
|
||||||
|
|
||||||
<ImageView
|
<ImageView
|
||||||
@ -32,7 +32,7 @@
|
|||||||
android:layout_width="match_parent"
|
android:layout_width="match_parent"
|
||||||
android:layout_height="wrap_content"
|
android:layout_height="wrap_content"
|
||||||
android:layout_gravity="center_vertical"
|
android:layout_gravity="center_vertical"
|
||||||
android:textColor="@color/white"
|
android:textColor="?attr/primaryTextColor"
|
||||||
android:maxLines="1"
|
android:maxLines="1"
|
||||||
android:textSize="20sp" />
|
android:textSize="20sp" />
|
||||||
|
|
||||||
@ -58,7 +58,7 @@
|
|||||||
android:layout_margin="15dp"
|
android:layout_margin="15dp"
|
||||||
android:gravity="center"
|
android:gravity="center"
|
||||||
android:text="@string/noDataFound"
|
android:text="@string/noDataFound"
|
||||||
android:textColor="@color/white"
|
android:textColor="?attr/primaryTextColor"
|
||||||
android:textSize="20sp"
|
android:textSize="20sp"
|
||||||
android:visibility="gone" />
|
android:visibility="gone" />
|
||||||
|
|
||||||
|
@ -4,7 +4,7 @@
|
|||||||
android:id="@+id/gridViewData"
|
android:id="@+id/gridViewData"
|
||||||
android:layout_width="match_parent"
|
android:layout_width="match_parent"
|
||||||
android:layout_height="wrap_content"
|
android:layout_height="wrap_content"
|
||||||
android:background="@color/colorPrimary"
|
android:background="?attr/primaryBackgroundColor"
|
||||||
android:orientation="vertical">
|
android:orientation="vertical">
|
||||||
|
|
||||||
<ImageView
|
<ImageView
|
||||||
@ -22,6 +22,6 @@
|
|||||||
android:layout_marginTop="1dp"
|
android:layout_marginTop="1dp"
|
||||||
android:text="@string/tab_text_collaborators"
|
android:text="@string/tab_text_collaborators"
|
||||||
android:textSize="14sp"
|
android:textSize="14sp"
|
||||||
android:textColor="@color/white" />
|
android:textColor="?attr/primaryTextColor" />
|
||||||
|
|
||||||
</LinearLayout>
|
</LinearLayout>
|
@ -2,7 +2,7 @@
|
|||||||
<RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android"
|
<RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android"
|
||||||
android:layout_width="match_parent"
|
android:layout_width="match_parent"
|
||||||
android:layout_height="match_parent"
|
android:layout_height="match_parent"
|
||||||
android:background="@color/colorPrimary"
|
android:background="?attr/primaryBackgroundColor"
|
||||||
android:orientation="vertical">
|
android:orientation="vertical">
|
||||||
|
|
||||||
<GridView
|
<GridView
|
||||||
@ -23,7 +23,7 @@
|
|||||||
android:layout_margin="15dp"
|
android:layout_margin="15dp"
|
||||||
android:gravity="center"
|
android:gravity="center"
|
||||||
android:text="@string/noDataCollaboratorTab"
|
android:text="@string/noDataCollaboratorTab"
|
||||||
android:textColor="@color/white"
|
android:textColor="?attr/primaryTextColor"
|
||||||
android:textSize="20sp"
|
android:textSize="20sp"
|
||||||
android:visibility="gone" />
|
android:visibility="gone" />
|
||||||
|
|
||||||
|
@ -4,7 +4,7 @@
|
|||||||
android:id="@+id/gridViewData"
|
android:id="@+id/gridViewData"
|
||||||
android:layout_width="match_parent"
|
android:layout_width="match_parent"
|
||||||
android:layout_height="wrap_content"
|
android:layout_height="wrap_content"
|
||||||
android:background="@color/colorPrimary"
|
android:background="?attr/primaryBackgroundColor"
|
||||||
android:orientation="vertical">
|
android:orientation="vertical">
|
||||||
|
|
||||||
<ImageView
|
<ImageView
|
||||||
@ -22,6 +22,6 @@
|
|||||||
android:layout_marginTop="1dp"
|
android:layout_marginTop="1dp"
|
||||||
android:text="@string/starMember"
|
android:text="@string/starMember"
|
||||||
android:textSize="14sp"
|
android:textSize="14sp"
|
||||||
android:textColor="@color/white" />
|
android:textColor="?attr/primaryTextColor" />
|
||||||
|
|
||||||
</LinearLayout>
|
</LinearLayout>
|
@ -4,7 +4,7 @@
|
|||||||
android:id="@+id/gridViewData"
|
android:id="@+id/gridViewData"
|
||||||
android:layout_width="match_parent"
|
android:layout_width="match_parent"
|
||||||
android:layout_height="wrap_content"
|
android:layout_height="wrap_content"
|
||||||
android:background="@color/colorPrimary"
|
android:background="?attr/primaryBackgroundColor"
|
||||||
android:orientation="vertical">
|
android:orientation="vertical">
|
||||||
|
|
||||||
<ImageView
|
<ImageView
|
||||||
@ -22,6 +22,6 @@
|
|||||||
android:layout_marginTop="1dp"
|
android:layout_marginTop="1dp"
|
||||||
android:text="@string/watcherMember"
|
android:text="@string/watcherMember"
|
||||||
android:textSize="14sp"
|
android:textSize="14sp"
|
||||||
android:textColor="@color/white" />
|
android:textColor="?attr/primaryTextColor" />
|
||||||
|
|
||||||
</LinearLayout>
|
</LinearLayout>
|
@ -7,7 +7,7 @@ buildscript {
|
|||||||
jcenter()
|
jcenter()
|
||||||
}
|
}
|
||||||
dependencies {
|
dependencies {
|
||||||
classpath 'com.android.tools.build:gradle:3.5.3'
|
classpath 'com.android.tools.build:gradle:3.6.1'
|
||||||
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
4
gradle/wrapper/gradle-wrapper.properties
vendored
4
gradle/wrapper/gradle-wrapper.properties
vendored
@ -1,6 +1,6 @@
|
|||||||
#Thu Sep 12 16:12:36 SGT 2019
|
#Wed Mar 04 00:16:50 SGT 2020
|
||||||
distributionBase=GRADLE_USER_HOME
|
distributionBase=GRADLE_USER_HOME
|
||||||
distributionPath=wrapper/dists
|
distributionPath=wrapper/dists
|
||||||
zipStoreBase=GRADLE_USER_HOME
|
zipStoreBase=GRADLE_USER_HOME
|
||||||
zipStorePath=wrapper/dists
|
zipStorePath=wrapper/dists
|
||||||
distributionUrl=https\://services.gradle.org/distributions/gradle-5.4.1-all.zip
|
distributionUrl=https\://services.gradle.org/distributions/gradle-5.6.4-all.zip
|
||||||
|
Loading…
Reference in New Issue
Block a user