Loading res/values/strings.xml +16 −2 Original line number Diff line number Diff line Loading @@ -709,9 +709,23 @@ <string name="pref_debug_traces_off">Capture of debug traces is disabled</string> <!-- Security * Extract relative or absolute files --> <string name="security_warning_extract">Warning!\n\n Extracting an archive file with relative or absolute paths may cause damage to your system, <string name="security_warning_extract">Warning!\n \nExtracting an archive file with relative or absolute paths may cause damage to your system, because the operation could overwrite some of the system files.\n\n Continue?</string> <!-- Welcome Dialog * Title --> <string name="welcome_title">Welcome</string> <!-- Welcome Dialog * Message --> <string name="welcome_msg"> Welcome to the CyanogenMod file manager. \n\nThis app allow you to explore all the file system and do operations that could break your device. For this reason, the first time, the app will run in a low-privileged environment. This ensure you to break anything. \n\nYou can access to a privileged environment at general settings. Using the advanced mode allow you to select between a low-privileged environment (where you are asked to gain privileges) and a full privileged environment. Under, this environment, it\'s your responsability to ensure that an operation doesn\'t break your system. \n\nThe CyanogenMod Team.</string> </resources> No newline at end of file src/com/cyanogenmod/explorer/activities/NavigationActivity.java +26 −0 Original line number Diff line number Diff line Loading @@ -245,6 +245,9 @@ public class NavigationActivity extends Activity //Set the main layout of the activity setContentView(R.layout.navigation); // Show welcome message showWelcomeMsg(); //Initialize activity init(); Loading Loading @@ -332,6 +335,29 @@ public class NavigationActivity extends Activity this.mHistory = new ArrayList<History>(); } /** * Method that displays a welcome message the first time the user * access the application */ private void showWelcomeMsg() { boolean firstUse = Preferences.getSharedPreferences().getBoolean( ExplorerSettings.SETTINGS_FIRST_USE.getId(), ((Boolean)ExplorerSettings.SETTINGS_FIRST_USE.getDefaultValue()).booleanValue()); //Display the welcome message? if (firstUse) { AlertDialog dialog = DialogHelper.createAlertDialog( this, R.drawable.ic_launcher, R.string.welcome_title, R.string.welcome_msg); dialog.show(); // Don't display again this dialog try { Preferences.savePreference( ExplorerSettings.SETTINGS_FIRST_USE, Boolean.FALSE, true); } catch (Exception e) {/**NON BLOCK**/} } } /** * Method that initializes the titlebar of the activity. */ Loading src/com/cyanogenmod/explorer/preferences/ExplorerSettings.java +6 −0 Original line number Diff line number Diff line Loading @@ -23,6 +23,12 @@ import com.cyanogenmod.explorer.util.FileHelper; * The enumeration of settings of Explorer application. */ public enum ExplorerSettings { /** * Whether is the first use of the application * @hide */ SETTINGS_FIRST_USE("cm_explorer_first_use", Boolean.TRUE), //$NON-NLS-1$ /** * Whether use SUPERUSER mode. * @hide Loading Loading
res/values/strings.xml +16 −2 Original line number Diff line number Diff line Loading @@ -709,9 +709,23 @@ <string name="pref_debug_traces_off">Capture of debug traces is disabled</string> <!-- Security * Extract relative or absolute files --> <string name="security_warning_extract">Warning!\n\n Extracting an archive file with relative or absolute paths may cause damage to your system, <string name="security_warning_extract">Warning!\n \nExtracting an archive file with relative or absolute paths may cause damage to your system, because the operation could overwrite some of the system files.\n\n Continue?</string> <!-- Welcome Dialog * Title --> <string name="welcome_title">Welcome</string> <!-- Welcome Dialog * Message --> <string name="welcome_msg"> Welcome to the CyanogenMod file manager. \n\nThis app allow you to explore all the file system and do operations that could break your device. For this reason, the first time, the app will run in a low-privileged environment. This ensure you to break anything. \n\nYou can access to a privileged environment at general settings. Using the advanced mode allow you to select between a low-privileged environment (where you are asked to gain privileges) and a full privileged environment. Under, this environment, it\'s your responsability to ensure that an operation doesn\'t break your system. \n\nThe CyanogenMod Team.</string> </resources> No newline at end of file
src/com/cyanogenmod/explorer/activities/NavigationActivity.java +26 −0 Original line number Diff line number Diff line Loading @@ -245,6 +245,9 @@ public class NavigationActivity extends Activity //Set the main layout of the activity setContentView(R.layout.navigation); // Show welcome message showWelcomeMsg(); //Initialize activity init(); Loading Loading @@ -332,6 +335,29 @@ public class NavigationActivity extends Activity this.mHistory = new ArrayList<History>(); } /** * Method that displays a welcome message the first time the user * access the application */ private void showWelcomeMsg() { boolean firstUse = Preferences.getSharedPreferences().getBoolean( ExplorerSettings.SETTINGS_FIRST_USE.getId(), ((Boolean)ExplorerSettings.SETTINGS_FIRST_USE.getDefaultValue()).booleanValue()); //Display the welcome message? if (firstUse) { AlertDialog dialog = DialogHelper.createAlertDialog( this, R.drawable.ic_launcher, R.string.welcome_title, R.string.welcome_msg); dialog.show(); // Don't display again this dialog try { Preferences.savePreference( ExplorerSettings.SETTINGS_FIRST_USE, Boolean.FALSE, true); } catch (Exception e) {/**NON BLOCK**/} } } /** * Method that initializes the titlebar of the activity. */ Loading
src/com/cyanogenmod/explorer/preferences/ExplorerSettings.java +6 −0 Original line number Diff line number Diff line Loading @@ -23,6 +23,12 @@ import com.cyanogenmod.explorer.util.FileHelper; * The enumeration of settings of Explorer application. */ public enum ExplorerSettings { /** * Whether is the first use of the application * @hide */ SETTINGS_FIRST_USE("cm_explorer_first_use", Boolean.TRUE), //$NON-NLS-1$ /** * Whether use SUPERUSER mode. * @hide Loading