Skip to content
This repository was archived by the owner on Jan 30, 2025. It is now read-only.

Commit c2dd21f

Browse files
committed
Update code to most recent develop
1 parent a272548 commit c2dd21f

File tree

2 files changed

+6
-5
lines changed

2 files changed

+6
-5
lines changed

vector/src/main/java/im/vector/activity/MediasPreviewerActivity.java

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -36,8 +36,7 @@ public class MediasPreviewerActivity extends MXCActionBarActivity {
3636
private static final String LOG_TAG = MediasPreviewerActivity.class.getSimpleName();
3737

3838
@Override
39-
protected void onCreate(Bundle savedInstanceState) {
40-
super.onCreate(savedInstanceState);
39+
public void initUiAndData() {
4140

4241
if (CommonActivityUtils.shouldRestartApp(this)) {
4342
Log.d(LOG_TAG, "onCreate : restart the application");
@@ -50,8 +49,6 @@ protected void onCreate(Bundle savedInstanceState) {
5049
return;
5150
}
5251

53-
setContentView(R.layout.activity_medias_previewer);
54-
5552
Toolbar toolbar = (android.support.v7.widget.Toolbar) findViewById(R.id.room_toolbar);
5653

5754
setSupportActionBar(toolbar);
@@ -137,4 +134,8 @@ private int getStatusBarHeight() {
137134
return result;
138135
}
139136

137+
@Override
138+
public int getLayoutRes() {
139+
return R.layout.activity_medias_previewer;
140+
}
140141
}

vector/src/main/java/im/vector/util/PreferencesManager.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -701,7 +701,7 @@ public static void setUseAnalytics(Context context, boolean useAnalytics) {
701701
* @return true to preview media
702702
*/
703703
public static boolean previewMediaWhenSending(Context context) {
704-
return PreferenceManager.getDefaultSharedPreferences(context).getBoolean(SETTINGS_PREVIEW_MEDIA_BEFORE_SENDING_KEY, false);
704+
return PreferenceManager.getDefaultSharedPreferences(context).getBoolean(SETTINGS_PREVIEW_MEDIA_BEFORE_SENDING_KEY, true);
705705
}
706706

707707
/**

0 commit comments

Comments
 (0)