@Override
 protected void onCreate(Bundle savedInstanceState) {
   Log.v("cr3", "creating BookmarksDlg");
   setTitle(mCoolReader.getResources().getString(R.string.win_title_bookmarks));
   setCancelable(true);
   mInflater = LayoutInflater.from(getContext());
   super.onCreate(savedInstanceState);
   registerForContextMenu(mList);
   // mList.
 }
Beispiel #2
0
 public BookmarksDlg(CoolReader activity, ReaderView readerView) {
   super(activity, activity.getResources().getString(R.string.win_title_bookmarks), true, false);
   mThis = this; // for inner classes
   mInflater = LayoutInflater.from(getContext());
   mCoolReader = activity;
   mReaderView = readerView;
   mBookInfo = mReaderView.getBookInfo();
   setPositiveButtonImage(R.drawable.cr3_button_add, R.string.mi_bookmark_add);
   View frame = mInflater.inflate(R.layout.bookmark_list_dialog, null);
   ViewGroup body = (ViewGroup) frame.findViewById(R.id.bookmark_list);
   mList = new BookmarkList(activity, false);
   body.addView(mList);
   setView(frame);
   setFlingHandlers(mList, null, null);
 }
Beispiel #3
0
 private boolean addMountRoot(Map<String, String> list, String pathname, int resourceId) {
   return addMountRoot(list, pathname, mActivity.getResources().getString(resourceId));
 }
Beispiel #4
0
 // public void setProgressDrawable( final BitmapDrawable drawable )
 // {
 // if ( enable_progress ) {
 // mBackgroundThread.executeGUI( new Runnable() {
 // public void run() {
 // // show progress
 // log.v("showProgress() - in GUI thread");
 // if ( mProgress!=null && progressShown ) {
 // hideProgress();
 // progressIcon = drawable;
 // showProgress(mProgressPos, mProgressMessage);
 // //mProgress.setIcon(drawable);
 // }
 // }
 // });
 // }
 // }
 public void showProgress(final int mainProgress, final int resourceId) {
   showProgress(mainProgress, mActivity.getResources().getString(resourceId));
 }