public abstract class CPDFBaseAnnotImpl<Annotation extends CPDFAnnotation> extends java.lang.Object implements IAnnotationImpl<Annotation>, com.compdfkit.ui.internal.UndoAnnotation
Modifier and Type | Field and Description |
---|---|
int |
annotIndex |
boolean |
isDirty
when the appearance of the annotation is an image (such as Ink and Stamp), isDirty is true, and the image is retrieved from the library
|
Constructor and Description |
---|
CPDFBaseAnnotImpl() |
Modifier and Type | Method and Description |
---|---|
boolean |
checkFocusable() |
CPDFReaderView.CheckFocusType |
checkFocusType() |
void |
close() |
boolean |
compare(com.compdfkit.ui.internal.UndoAnnotation undoAnnotation) |
android.graphics.RectF |
getAnnotationRect() |
CPDFAnnotationUndoAttr |
getAnnotAttr() |
CPDFAnnotation.Type |
getAnnotType() |
long |
getId() |
boolean |
isFocused() |
boolean |
isVisible() |
void |
onInit(ReaderView readerView,
PageView pageView,
CPDFPage tpdfPage,
Annotation annotation)
Initialization, set initial value of
CPDFReaderView in current class instance, CPDFPageView , CPDFPage , CPDFAnnotation . |
boolean |
onLongPress(float x,
float y)
Called when a long press occurs .
|
boolean |
redo(CPDFAnnotationUndoAttr annotationAttr,
int affectPage,
boolean highlight,
com.compdfkit.ui.internal.UndoAnnotation.Callback callback) |
void |
release()
release resources
|
void |
setFocused(boolean focused) |
void |
setVisible(boolean isVisible) |
boolean |
undo(CPDFAnnotationUndoAttr annotationAttr,
int affectPage,
boolean highlight,
com.compdfkit.ui.internal.UndoAnnotation.Callback callback) |
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
onAnnotAttrChange, onGetAnnotation
onDraw
onSingleTapUp, onTouchEvent
public boolean isDirty
public int annotIndex
public boolean isFocused()
public void setFocused(boolean focused)
public void onInit(ReaderView readerView, PageView pageView, CPDFPage tpdfPage, Annotation annotation)
IAnnotationImpl
CPDFReaderView
in current class instance, CPDFPageView
, CPDFPage
, CPDFAnnotation
.onInit
in interface IAnnotationImpl<Annotation extends CPDFAnnotation>
readerView
- Used for showing View
in the whole documentpageView
- Used for showing View
of each page in the documenttpdfPage
- Page object of document, more: CPDFPage
annotation
- Annotation object of document, more: CPDFAnnotation
public void setVisible(boolean isVisible)
public boolean isVisible()
public boolean onLongPress(float x, float y)
IInputEventHandler
onLongPress
in interface IInputEventHandler
x
- The x coordinate on the page.y
- The y coordinate on the page.public boolean checkFocusable()
public CPDFReaderView.CheckFocusType checkFocusType()
public CPDFAnnotation.Type getAnnotType()
getAnnotType
in interface com.compdfkit.ui.internal.UndoAnnotation
public boolean redo(CPDFAnnotationUndoAttr annotationAttr, int affectPage, boolean highlight, com.compdfkit.ui.internal.UndoAnnotation.Callback callback)
redo
in interface com.compdfkit.ui.internal.UndoAnnotation
public boolean undo(CPDFAnnotationUndoAttr annotationAttr, int affectPage, boolean highlight, com.compdfkit.ui.internal.UndoAnnotation.Callback callback)
undo
in interface com.compdfkit.ui.internal.UndoAnnotation
public android.graphics.RectF getAnnotationRect()
public boolean compare(com.compdfkit.ui.internal.UndoAnnotation undoAnnotation)
compare
in interface com.compdfkit.ui.internal.UndoAnnotation
public CPDFAnnotationUndoAttr getAnnotAttr()
getAnnotAttr
in interface com.compdfkit.ui.internal.UndoAnnotation
public void close()
close
in interface com.compdfkit.ui.internal.UndoAnnotation
public long getId()
getId
in interface com.compdfkit.ui.internal.UndoAnnotation
public void release()