Merge branch 'master' of gitea.com:mmarif/GitNex

This commit is contained in:
M M Arif 2019-10-01 11:44:45 +05:00
commit e4700ffd69
21 changed files with 275 additions and 291 deletions

View File

@ -478,7 +478,7 @@ public class IssueDetailActivity extends AppCompatActivity {
case "pretty": { case "pretty": {
PrettyTime prettyTime = new PrettyTime(new Locale(locale)); PrettyTime prettyTime = new PrettyTime(new Locale(locale));
String createdTime = prettyTime.format(singleIssue.getCreated_at()); String createdTime = prettyTime.format(singleIssue.getCreated_at());
issueCreatedTime.setText(getString(R.string.createdTime, createdTime)); issueCreatedTime.setText(createdTime);
issueCreatedTime.setVisibility(View.VISIBLE); issueCreatedTime.setVisibility(View.VISIBLE);
issueCreatedTime.setOnClickListener(new ClickListener(TimeHelper.customDateFormatForToastDateFormat(singleIssue.getCreated_at()), getApplicationContext())); issueCreatedTime.setOnClickListener(new ClickListener(TimeHelper.customDateFormatForToastDateFormat(singleIssue.getCreated_at()), getApplicationContext()));
break; break;
@ -486,14 +486,14 @@ public class IssueDetailActivity extends AppCompatActivity {
case "normal": { case "normal": {
DateFormat formatter = new SimpleDateFormat("yyyy-MM-dd '" + getResources().getString(R.string.timeAtText) + "' HH:mm", new Locale(locale)); DateFormat formatter = new SimpleDateFormat("yyyy-MM-dd '" + getResources().getString(R.string.timeAtText) + "' HH:mm", new Locale(locale));
String createdTime = formatter.format(singleIssue.getCreated_at()); String createdTime = formatter.format(singleIssue.getCreated_at());
issueCreatedTime.setText(getString(R.string.createdTime, createdTime)); issueCreatedTime.setText(createdTime);
issueCreatedTime.setVisibility(View.VISIBLE); issueCreatedTime.setVisibility(View.VISIBLE);
break; break;
} }
case "normal1": { case "normal1": {
DateFormat formatter = new SimpleDateFormat("dd-MM-yyyy '" + getResources().getString(R.string.timeAtText) + "' HH:mm", new Locale(locale)); DateFormat formatter = new SimpleDateFormat("dd-MM-yyyy '" + getResources().getString(R.string.timeAtText) + "' HH:mm", new Locale(locale));
String createdTime = formatter.format(singleIssue.getCreated_at()); String createdTime = formatter.format(singleIssue.getCreated_at());
issueCreatedTime.setText(getString(R.string.createdTime, createdTime)); issueCreatedTime.setText(createdTime);
issueCreatedTime.setVisibility(View.VISIBLE); issueCreatedTime.setVisibility(View.VISIBLE);
break; break;
} }

View File

@ -13,6 +13,7 @@ import org.mian.gitnex.activities.AddRemoveAssigneesActivity;
import org.mian.gitnex.activities.AddRemoveLabelsActivity; import org.mian.gitnex.activities.AddRemoveLabelsActivity;
import org.mian.gitnex.activities.EditIssueActivity; import org.mian.gitnex.activities.EditIssueActivity;
import org.mian.gitnex.activities.ReplyToIssueActivity; import org.mian.gitnex.activities.ReplyToIssueActivity;
import org.mian.gitnex.helpers.Toasty;
import org.mian.gitnex.util.TinyDB; import org.mian.gitnex.util.TinyDB;
import androidx.annotation.NonNull; import androidx.annotation.NonNull;
import androidx.annotation.Nullable; import androidx.annotation.Nullable;
@ -102,6 +103,8 @@ public class SingleIssueBottomSheetFragment extends BottomSheetDialogFragment {
dismiss(); dismiss();
Toasty.info(getContext(), getContext().getString(R.string.copyIssueUrlToastMsg));
} }
}); });

View File

@ -0,0 +1,5 @@
<vector android:height="20dp" android:tint="#FFFFFF"
android:viewportHeight="24.0" android:viewportWidth="24.0"
android:width="20dp" xmlns:android="http://schemas.android.com/apk/res/android">
<path android:fillColor="#FF000000" android:pathData="M21.99,4c0,-1.1 -0.89,-2 -1.99,-2H4c-1.1,0 -2,0.9 -2,2v12c0,1.1 0.9,2 2,2h14l4,4 -0.01,-18z"/>
</vector>

View File

@ -1,6 +1,6 @@
<?xml version="1.0" encoding="UTF-8"?> <?xml version="1.0" encoding="UTF-8"?>
<shape xmlns:android="http://schemas.android.com/apk/res/android" <shape xmlns:android="http://schemas.android.com/apk/res/android"
android:shape="rectangle" > android:shape="rectangle" >
<corners android:radius="35dp"/> <corners android:radius="5dp"/>
</shape> </shape>

View File

@ -51,7 +51,6 @@
android:id="@+id/assigneeAvatar" android:id="@+id/assigneeAvatar"
android:layout_width="48dp" android:layout_width="48dp"
android:layout_height="48dp" android:layout_height="48dp"
android:layout_marginTop="5dp"
android:layout_marginEnd="15dp" android:layout_marginEnd="15dp"
android:contentDescription="@string/generalImgContentText" /> android:contentDescription="@string/generalImgContentText" />

View File

@ -21,7 +21,6 @@
android:layout_width="wrap_content" android:layout_width="wrap_content"
android:layout_height="wrap_content" android:layout_height="wrap_content"
android:layout_gravity="center" android:layout_gravity="center"
android:layout_marginTop="5dp"
android:contentDescription="@string/generalImgContentText" android:contentDescription="@string/generalImgContentText"
android:src="@drawable/ic_android" /> android:src="@drawable/ic_android" />
@ -31,7 +30,6 @@
android:layout_height="wrap_content" android:layout_height="wrap_content"
android:layout_gravity="center_horizontal" android:layout_gravity="center_horizontal"
android:scaleType="fitCenter" android:scaleType="fitCenter"
android:layout_marginTop="5dp"
android:contentDescription="@string/userRoleAdmin" android:contentDescription="@string/userRoleAdmin"
android:src="@drawable/ic_android" /> android:src="@drawable/ic_android" />

View File

@ -13,7 +13,6 @@
android:layout_width="40dp" android:layout_width="40dp"
android:layout_height="40dp" android:layout_height="40dp"
android:layout_marginEnd="15dp" android:layout_marginEnd="15dp"
android:layout_marginTop="5dp"
android:contentDescription="@string/generalImgContentText" android:contentDescription="@string/generalImgContentText"
android:src="@drawable/ic_android" /> android:src="@drawable/ic_android" />

View File

@ -23,8 +23,6 @@
android:layout_width="80dp" android:layout_width="80dp"
android:layout_height="80dp" android:layout_height="80dp"
android:layout_gravity="start" android:layout_gravity="start"
android:layout_marginTop="2dp"
android:layout_marginBottom="5dp"
android:contentDescription="@string/logo" android:contentDescription="@string/logo"
android:src="@mipmap/app_logo_round" /> android:src="@mipmap/app_logo_round" />

View File

@ -34,8 +34,6 @@
android:layout_width="48dp" android:layout_width="48dp"
android:layout_height="48dp" android:layout_height="48dp"
android:layout_marginEnd="15dp" android:layout_marginEnd="15dp"
android:layout_marginTop="5dp"
android:layout_marginBottom="5dp"
android:contentDescription="@string/generalImgContentText" android:contentDescription="@string/generalImgContentText"
android:src="@drawable/ic_android" /> android:src="@drawable/ic_android" />

View File

@ -22,7 +22,6 @@
android:layout_width="40dp" android:layout_width="40dp"
android:layout_height="40dp" android:layout_height="40dp"
android:layout_marginEnd="15dp" android:layout_marginEnd="15dp"
android:layout_marginTop="5dp"
android:contentDescription="@string/repoContentAvatar" android:contentDescription="@string/repoContentAvatar"
android:src="@drawable/ic_android" /> android:src="@drawable/ic_android" />
@ -53,9 +52,8 @@
android:layout_weight=".05" android:layout_weight=".05"
android:id="@+id/imageRepoTypeMy" android:id="@+id/imageRepoTypeMy"
android:layout_width="10dp" android:layout_width="10dp"
android:layout_height="25dp" android:layout_height="20dp"
android:layout_gravity="end" android:layout_gravity="end"
android:layout_marginTop="5dp"
android:contentDescription="@string/privateAvatar" android:contentDescription="@string/privateAvatar"
android:src="@drawable/ic_lock_bold" /> android:src="@drawable/ic_lock_bold" />

View File

@ -22,7 +22,6 @@
android:layout_width="40dp" android:layout_width="40dp"
android:layout_height="40dp" android:layout_height="40dp"
android:layout_marginEnd="15dp" android:layout_marginEnd="15dp"
android:layout_marginTop="5dp"
android:layout_marginBottom="5dp" android:layout_marginBottom="5dp"
android:src="@drawable/ic_android" android:src="@drawable/ic_android"
android:contentDescription="@string/orgContentAvatar"/> android:contentDescription="@string/orgContentAvatar"/>

View File

@ -13,8 +13,6 @@
android:layout_width="wrap_content" android:layout_width="wrap_content"
android:layout_height="wrap_content" android:layout_height="wrap_content"
android:layout_marginEnd="15dp" android:layout_marginEnd="15dp"
android:layout_marginTop="5dp"
android:layout_marginBottom="5dp"
android:contentDescription="@string/generalImgContentText" android:contentDescription="@string/generalImgContentText"
android:src="@drawable/ic_android" /> android:src="@drawable/ic_android" />

View File

@ -13,8 +13,6 @@
android:layout_width="wrap_content" android:layout_width="wrap_content"
android:layout_height="wrap_content" android:layout_height="wrap_content"
android:layout_marginEnd="15dp" android:layout_marginEnd="15dp"
android:layout_marginTop="5dp"
android:layout_marginBottom="5dp"
android:contentDescription="@string/generalImgContentText" android:contentDescription="@string/generalImgContentText"
android:src="@drawable/ic_android" /> android:src="@drawable/ic_android" />

View File

@ -20,8 +20,6 @@
android:layout_width="48dp" android:layout_width="48dp"
android:layout_height="48dp" android:layout_height="48dp"
android:layout_marginEnd="15dp" android:layout_marginEnd="15dp"
android:layout_marginTop="5dp"
android:layout_marginBottom="5dp"
android:contentDescription="@string/generalImgContentText" android:contentDescription="@string/generalImgContentText"
android:src="@drawable/ic_android" /> android:src="@drawable/ic_android" />
@ -57,9 +55,8 @@
<ImageView <ImageView
android:id="@+id/issueType" android:id="@+id/issueType"
android:layout_width="16dp" android:layout_width="20dp"
android:layout_height="21dp" android:layout_height="20dp"
android:layout_marginTop="5dp"
android:layout_gravity="center_horizontal" android:layout_gravity="center_horizontal"
android:contentDescription="@string/generalImgContentText" android:contentDescription="@string/generalImgContentText"
android:src="@drawable/ic_issues" /> android:src="@drawable/ic_issues" />
@ -86,10 +83,10 @@
android:layout_height="wrap_content" android:layout_height="wrap_content"
android:gravity="start" android:gravity="start"
android:drawablePadding="5dp" android:drawablePadding="5dp"
android:drawableStart="@drawable/ic_comment_16" android:drawableStart="@drawable/ic_comment_20"
android:layout_gravity="center_horizontal" android:layout_gravity="center_horizontal"
android:textColor="@color/colorWhite" android:textColor="@color/colorWhite"
android:textSize="12sp" /> android:textSize="14sp" />
</LinearLayout> </LinearLayout>
@ -100,7 +97,7 @@
android:layout_height="wrap_content" android:layout_height="wrap_content"
android:gravity="end" android:gravity="end"
android:textColor="@color/colorWhite" android:textColor="@color/colorWhite"
android:textSize="12sp" /> android:textSize="14sp" />
</LinearLayout> </LinearLayout>

View File

@ -23,7 +23,6 @@
android:layout_height="40dp" android:layout_height="40dp"
android:layout_marginEnd="15dp" android:layout_marginEnd="15dp"
android:contentDescription="@string/repoContentAvatar" android:contentDescription="@string/repoContentAvatar"
android:layout_marginTop="5dp"
android:src="@drawable/ic_android" /> android:src="@drawable/ic_android" />
<LinearLayout <LinearLayout
@ -53,9 +52,8 @@
android:layout_weight=".05" android:layout_weight=".05"
android:id="@+id/imageRepoType" android:id="@+id/imageRepoType"
android:layout_width="10dp" android:layout_width="10dp"
android:layout_height="25dp" android:layout_height="20dp"
android:layout_gravity="end" android:layout_gravity="end"
android:layout_marginTop="5dp"
android:contentDescription="@string/privateAvatar" android:contentDescription="@string/privateAvatar"
android:src="@drawable/ic_lock_24dp" /> android:src="@drawable/ic_lock_24dp" />

View File

@ -1,20 +1,17 @@
<?xml version="1.0" encoding="utf-8"?> <?xml version="1.0" encoding="utf-8"?>
<RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:background="@color/backgroundColor" >
<RelativeLayout <RelativeLayout
xmlns:tools="http://schemas.android.com/tools" xmlns:tools="http://schemas.android.com/tools"
xmlns:android="http://schemas.android.com/apk/res/android"
android:id="@+id/linearLayoutFrame" android:id="@+id/linearLayoutFrame"
android:layout_width="match_parent" android:layout_width="match_parent"
android:layout_height="match_parent" android:layout_height="wrap_content"
android:layout_alignParentTop="true" android:layout_alignParentTop="true"
android:layout_marginTop="0dp" android:layout_marginTop="0dp"
android:fitsSystemWindows="true" android:fitsSystemWindows="true"
android:orientation="vertical" android:orientation="vertical"
android:layout_margin="10dp" android:layout_margin="10dp"
android:theme="@style/AppTheme" android:theme="@style/AppTheme"
android:background="@color/backgroundColor"
tools:context=".activities.MainActivity"> tools:context=".activities.MainActivity">
<ImageView <ImageView
@ -22,7 +19,6 @@
android:layout_width="40dp" android:layout_width="40dp"
android:layout_height="40dp" android:layout_height="40dp"
android:layout_marginEnd="15dp" android:layout_marginEnd="15dp"
android:layout_marginTop="5dp"
android:contentDescription="@string/repoContentAvatar" android:contentDescription="@string/repoContentAvatar"
android:src="@drawable/ic_android" /> android:src="@drawable/ic_android" />
@ -53,9 +49,8 @@
android:layout_weight=".05" android:layout_weight=".05"
android:id="@+id/imageRepoType" android:id="@+id/imageRepoType"
android:layout_width="10dp" android:layout_width="10dp"
android:layout_height="25dp" android:layout_height="20dp"
android:layout_gravity="end" android:layout_gravity="end"
android:layout_marginTop="5dp"
android:contentDescription="@string/privateAvatar" android:contentDescription="@string/privateAvatar"
android:src="@drawable/ic_lock_24dp" /> android:src="@drawable/ic_lock_24dp" />
@ -142,4 +137,3 @@
</RelativeLayout> </RelativeLayout>
</RelativeLayout>

View File

@ -1,11 +1,8 @@
<?xml version="1.0" encoding="utf-8"?> <?xml version="1.0" encoding="utf-8"?>
<RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:background="@color/backgroundColor" >
<RelativeLayout <RelativeLayout
xmlns:tools="http://schemas.android.com/tools" xmlns:tools="http://schemas.android.com/tools"
xmlns:android="http://schemas.android.com/apk/res/android"
android:id="@+id/linearLayoutFrame" android:id="@+id/linearLayoutFrame"
android:layout_width="match_parent" android:layout_width="match_parent"
android:layout_height="match_parent" android:layout_height="match_parent"
@ -15,6 +12,7 @@
android:orientation="vertical" android:orientation="vertical"
android:padding="10dp" android:padding="10dp"
android:theme="@style/AppTheme" android:theme="@style/AppTheme"
android:background="@color/backgroundColor"
tools:context=".activities.MainActivity"> tools:context=".activities.MainActivity">
<ImageView <ImageView
@ -22,7 +20,6 @@
android:layout_width="40dp" android:layout_width="40dp"
android:layout_height="40dp" android:layout_height="40dp"
android:layout_marginEnd="15dp" android:layout_marginEnd="15dp"
android:layout_marginTop="5dp"
android:contentDescription="@string/repoContentAvatar" android:contentDescription="@string/repoContentAvatar"
android:src="@drawable/ic_android" /> android:src="@drawable/ic_android" />
@ -53,9 +50,8 @@
android:layout_weight=".05" android:layout_weight=".05"
android:id="@+id/imageRepoType" android:id="@+id/imageRepoType"
android:layout_width="10dp" android:layout_width="10dp"
android:layout_height="25dp" android:layout_height="20dp"
android:layout_gravity="end" android:layout_gravity="end"
android:layout_marginTop="5dp"
android:contentDescription="@string/privateAvatar" android:contentDescription="@string/privateAvatar"
android:src="@drawable/ic_lock_24dp" /> android:src="@drawable/ic_lock_24dp" />
@ -141,5 +137,3 @@
</LinearLayout> </LinearLayout>
</RelativeLayout> </RelativeLayout>
</RelativeLayout>

View File

@ -427,6 +427,9 @@
<string name="strFilter">Filter</string> <string name="strFilter">Filter</string>
<string name="copyIssueUrl">Issue URL kopieren</string>
<string name="copyIssueUrlToastMsg">Issue URL copied to clipboard</string>
<!-- generic copy --> <!-- generic copy -->
<string name="okButton">OK</string> <string name="okButton">OK</string>
<string name="doneButton">Fertig</string> <string name="doneButton">Fertig</string>
@ -447,7 +450,6 @@
<string name="websiteText">Website</string> <string name="websiteText">Website</string>
<string name="locationText">Standort</string> <string name="locationText">Standort</string>
<string name="characters255Limit">maximal 255 Zeichen</string> <string name="characters255Limit">maximal 255 Zeichen</string>
<string name="copyIssueUrl">Issue Url kopieren</string>
<!-- generic copy --> <!-- generic copy -->
</resources> </resources>

View File

@ -427,6 +427,9 @@
<string name="strFilter">Filter</string> <string name="strFilter">Filter</string>
<string name="copyIssueUrl">Copier l Issue URL</string>
<string name="copyIssueUrlToastMsg">Issue URL copied to clipboard</string>
<!-- generic copy --> <!-- generic copy -->
<string name="okButton">OK</string> <string name="okButton">OK</string>
<string name="doneButton">Done</string> <string name="doneButton">Done</string>
@ -448,7 +451,6 @@
<string name="locationText">Location</string> <string name="locationText">Location</string>
<string name="openWebRepo">Ouvrir avec le Browser</string> <string name="openWebRepo">Ouvrir avec le Browser</string>
<string name="characters255Limit">Max 255 characters</string> <string name="characters255Limit">Max 255 characters</string>
<string name="copyIssueUrl">Copier l Issue Url</string>
<!-- generic copy --> <!-- generic copy -->
</resources> </resources>

View File

@ -427,6 +427,9 @@
<string name="strFilter">Filter</string> <string name="strFilter">Filter</string>
<string name="copyIssueUrl">Copy Issue URL</string>
<string name="copyIssueUrlToastMsg">Issue URL copied to clipboard</string>
<!-- generic copy --> <!-- generic copy -->
<string name="okButton">OK</string> <string name="okButton">OK</string>
<string name="doneButton">Готово</string> <string name="doneButton">Готово</string>
@ -448,7 +451,6 @@
<string name="locationText">Место расположения</string> <string name="locationText">Место расположения</string>
<string name="openWebRepo">Открыть с помощью браузера</string> <string name="openWebRepo">Открыть с помощью браузера</string>
<string name="characters255Limit">Max 255 characters</string> <string name="characters255Limit">Max 255 characters</string>
<string name="copyIssueUrl">Copy Issue Url</string>
<!-- generic copy --> <!-- generic copy -->
</resources> </resources>

View File

@ -464,6 +464,9 @@
<string name="strFilter">Filter</string> <string name="strFilter">Filter</string>
<string name="copyIssueUrl">Copy Issue URL</string>
<string name="copyIssueUrlToastMsg">Issue URL copied to clipboard</string>
<!-- generic copy --> <!-- generic copy -->
<string name="okButton">OK</string> <string name="okButton">OK</string>
<string name="doneButton">Done</string> <string name="doneButton">Done</string>
@ -488,7 +491,6 @@
<string name="locationText">Location</string> <string name="locationText">Location</string>
<string name="characters255Limit">Max 255 characters</string> <string name="characters255Limit">Max 255 characters</string>
<string name="emptyFields">All fields are required</string> <string name="emptyFields">All fields are required</string>
<string name="copyIssueUrl">Copy Issue Url</string>
<!-- generic copy --> <!-- generic copy -->
</resources> </resources>