private int createFolder ( ) { if ( mNewDirectoryName != null && mSelectedDir != null && mSelectedDir . canWrite ( ) ) { final File newDir = new File ( mSelectedDir , mNewDirectoryName ) ; if ( newDir . exists ( ) ) { return R . string . create_folder_error_already_exists ; } else { final boolean result = newDir . mkdir ( ) ; if ( result ) { return R . string . create_folder_success ; } else { return R . string . create_folder_error ; } } } else if ( mSelectedDir != null && ! mSelectedDir . canWrite ( ) ) { return R . string . create_folder_error_no_write_access ; } else { return R . string . create_folder_error ; } }
Creates a new folder in the current directory with the name CREATE_DIRECTORY_NAME .