Example #1
0
  public synchronized Bitmap updatePage(
      BitmapHolder h,
      int page,
      int pageW,
      int pageH,
      int patchX,
      int patchY,
      int patchW,
      int patchH) {
    Bitmap bm = null;
    Bitmap old_bm = h.getBm();
    h.setBm(null);

    if (old_bm != null) bm = old_bm.copy(Bitmap.Config.ARGB_8888, false);

    old_bm = null;

    if (bm != null) {
      updatePageInternal(bm, page, pageW, pageH, patchX, patchY, patchW, patchH);
    } else {
      bm = Bitmap.createBitmap(patchW, patchH, Config.ARGB_8888);
      gotoPage(page);
      drawPage(bm, pageW, pageH, patchX, patchY, patchW, patchH);
    }

    return bm;
  }
Example #2
0
  public synchronized boolean setFocusedWidgetText(int page, String text) {
    boolean success;
    gotoPage(page);
    success = setFocusedWidgetTextInternal(text) != 0 ? true : false;

    return success;
  }
Example #3
0
 public synchronized Bitmap drawPage(
     int page, int pageW, int pageH, int patchX, int patchY, int patchW, int patchH) {
   gotoPage(page);
   Bitmap bm = Bitmap.createBitmap(patchW, patchH, Config.ARGB_8888);
   drawPage(bm, pageW, pageH, patchX, patchY, patchW, patchH);
   return bm;
 }
Example #4
0
 public synchronized PointF getPageSize(int page) {
   gotoPage(page);
   return new PointF(pageWidth, pageHeight);
 }
Example #5
0
 public synchronized RectF[] searchPage(int page, String text) {
   gotoPage(page);
   return searchPage(text);
 }