internal static void showDialog(FragmentManager manager, string title, string[] items) { Bundle args = new Bundle(); args.putString(KEY_TITLE, title); args.putStringArray(KEY_ITEMS, items); ListDialogFragment listDialogFragment = new ListDialogFragment(); listDialogFragment.Arguments = args; listDialogFragment.show(manager, TAG); }
private void showFileList() { File file = new File(PATH); File[] files = file.listFiles(new FileFilterAnonymousInnerClassHelper(this)); if (files != null && files.Length > 0) { string[] items = new string[files.Length]; for (int i = 0; i < items.Length; i++) { items[i] = files[i].AbsolutePath; } ListDialogFragment.showDialog(SupportFragmentManager, "PDF file list", items); } else { Toast.makeText(ApplicationContext, "No PDF file", Toast.LENGTH_SHORT).show(); } }
public OnClickListenerAnonymousInnerClassHelper(ListDialogFragment outerInstance, string[] items) { this.outerInstance = outerInstance; this.items = items; }