From 6a21c8a27cb2fc05de9fdd337bd5b3b130f6d170 Mon Sep 17 00:00:00 2001 From: tibbi Date: Thu, 23 Jun 2016 11:34:21 +0200 Subject: [PATCH] display the file path at the Edit dialog --- .../gallery/activities/ViewPagerActivity.java | 4 ++++ app/src/main/res/layout/rename_file.xml | 11 ++++++++++- 2 files changed, 14 insertions(+), 1 deletion(-) diff --git a/app/src/main/java/com/simplemobiletools/gallery/activities/ViewPagerActivity.java b/app/src/main/java/com/simplemobiletools/gallery/activities/ViewPagerActivity.java index de14f9115..54f60f3d5 100644 --- a/app/src/main/java/com/simplemobiletools/gallery/activities/ViewPagerActivity.java +++ b/app/src/main/java/com/simplemobiletools/gallery/activities/ViewPagerActivity.java @@ -18,6 +18,7 @@ import android.view.MotionEvent; import android.view.View; import android.widget.EditText; import android.widget.RelativeLayout; +import android.widget.TextView; import com.simplemobiletools.gallery.Constants; import com.simplemobiletools.gallery.MyViewPager; @@ -208,6 +209,9 @@ public class ViewPagerActivity extends AppCompatActivity final EditText extensionET = (EditText) renameFileView.findViewById(R.id.extension); extensionET.setText(extension); + final TextView filePath = (TextView) renameFileView.findViewById(R.id.file_path); + filePath.setText(file.getParent() + "/"); + final AlertDialog.Builder builder = new AlertDialog.Builder(this); builder.setTitle(getResources().getString(R.string.rename_file)); builder.setView(renameFileView); diff --git a/app/src/main/res/layout/rename_file.xml b/app/src/main/res/layout/rename_file.xml index 7f8007ebe..85d548f70 100644 --- a/app/src/main/res/layout/rename_file.xml +++ b/app/src/main/res/layout/rename_file.xml @@ -1,11 +1,19 @@ - + + @@ -18,6 +26,7 @@ android:singleLine="true"/>