Set attributes protected instead of private
This commit is contained in:
parent
38a1d32898
commit
1d976cd634
|
|
@ -67,7 +67,7 @@ public abstract class AbstractFilePickerActivity<T> extends Activity implements
|
|||
public static final String EXTRA_ALLOW_MULTIPLE = "android.intent.extra" +
|
||||
".ALLOW_MULTIPLE";
|
||||
public static final String EXTRA_PATHS = "nononsense.intent.PATHS";
|
||||
private static final String TAG = "filepicker_fragment";
|
||||
protected static final String TAG = "filepicker_fragment";
|
||||
|
||||
public static final int MODE_FILE = AbstractFilePickerFragment.MODE_FILE;
|
||||
public static final int MODE_FILE_AND_DIR = AbstractFilePickerFragment
|
||||
|
|
@ -75,7 +75,7 @@ public abstract class AbstractFilePickerActivity<T> extends Activity implements
|
|||
public static final int MODE_DIR = AbstractFilePickerFragment.MODE_DIR;
|
||||
|
||||
|
||||
private String startPath = null;
|
||||
protected String startPath = null;
|
||||
protected int mode = AbstractFilePickerFragment.MODE_FILE;
|
||||
protected boolean allowCreateDir = false;
|
||||
protected boolean allowMultiple = false;
|
||||
|
|
@ -111,7 +111,7 @@ public abstract class AbstractFilePickerActivity<T> extends Activity implements
|
|||
setResult(Activity.RESULT_CANCELED);
|
||||
}
|
||||
|
||||
private void setupFauxDialog() {
|
||||
protected void setupFauxDialog() {
|
||||
// Check if this should be a dialog
|
||||
TypedValue tv = new TypedValue();
|
||||
if (!getTheme().resolveAttribute(R.attr.isDialog, tv, true) || tv.data == 0) {
|
||||
|
|
@ -131,7 +131,7 @@ public abstract class AbstractFilePickerActivity<T> extends Activity implements
|
|||
getWindow().setAttributes(params);
|
||||
}
|
||||
|
||||
private void setupActionBar() {
|
||||
protected void setupActionBar() {
|
||||
getActionBar().setTitle(getWindowTitle());
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -67,7 +67,7 @@ public abstract class AbstractFilePickerFragment<T> extends
|
|||
// Allow multiple items to be selected.
|
||||
public static final String KEY_ALLOW_MULTIPLE = "KEY_ALLOW_MULTIPLE";
|
||||
// Used for saving state.
|
||||
private static final String KEY_CURRENT_PATH = "KEY_CURRENT PATH";
|
||||
protected static final String KEY_CURRENT_PATH = "KEY_CURRENT PATH";
|
||||
protected final DefaultHashMap<Integer, Boolean> checkedItems;
|
||||
protected T currentPath = null;
|
||||
protected boolean allowCreateDir = false;
|
||||
|
|
@ -146,7 +146,7 @@ public abstract class AbstractFilePickerFragment<T> extends
|
|||
setHasOptionsMenu(true);
|
||||
}
|
||||
|
||||
private boolean isCheckable(final T data) {
|
||||
protected boolean isCheckable(final T data) {
|
||||
final boolean checkable;
|
||||
if (isDir(data)) {
|
||||
checkable = ((mode == MODE_DIR && allowMultiple) ||
|
||||
|
|
@ -248,7 +248,7 @@ public abstract class AbstractFilePickerFragment<T> extends
|
|||
return view;
|
||||
}
|
||||
|
||||
private List<Uri> toUri(List<T> files) {
|
||||
protected List<Uri> toUri(List<T> files) {
|
||||
ArrayList<Uri> uris = new ArrayList<Uri>();
|
||||
for (T file : files) {
|
||||
uris.add(toUri(file));
|
||||
|
|
@ -302,7 +302,7 @@ public abstract class AbstractFilePickerFragment<T> extends
|
|||
}
|
||||
}
|
||||
|
||||
private void toggleItemCheck(final CheckedTextView view,
|
||||
protected void toggleItemCheck(final CheckedTextView view,
|
||||
final int position, final T data) {
|
||||
if (!isCheckable(data)) {
|
||||
return;
|
||||
|
|
|
|||
Loading…
Reference in New Issue