create an extra string resource
authorKeith Abdulla <email@ekeitho.com>
Tue, 23 Dec 2014 17:31:59 +0000 (09:31 -0800)
committerKeith Abdulla <email@ekeitho.com>
Tue, 23 Dec 2014 17:31:59 +0000 (09:31 -0800)
res/values/strings.xml
src/com/owncloud/android/operations/CreateShareOperation.java

index 04a88ad..de6ca8d 100644 (file)
 
        <string name="shared_subject_header">shared</string>
        <string name="with_you_subject_header">with you</string>
+    <string name="subject_token">%1$s %2$s &gt;&gt;%3$s&lt;&lt; %4$s</string>
 
 </resources>
index 72cbee4..fc44f53 100644 (file)
@@ -133,7 +133,7 @@ public class CreateShareOperation extends SyncOperation {
         OCFile file = getStorageManager().getFileByPath(mPath);
         if (file!=null) {
             mSendIntent.putExtra(Intent.EXTRA_TEXT, share.getShareLink());
-            mSendIntent.putExtra(Intent.EXTRA_SUBJECT, String.format("%s %s >>%s<< %s",
+            mSendIntent.putExtra(Intent.EXTRA_SUBJECT, String.format(mContext.getString(R.string.subject_token),
                     getClient().getCredentials().getUsername(), mContext.getString(R.string.shared_subject_header),
                     file.getFileName(), mContext.getString(R.string.with_you_subject_header)));
             file.setPublicLink(share.getShareLink());