java.lang.Object | |||
↳ | |||
↳ | com.pdftron.pdf.widget.recyclerview.SimpleRecyclerViewAdapter<T, VH extends RecyclerView.ViewHolder> | ||
↳ | com.pdftron.pdf.controls.ThumbnailsViewAdapter |
A Recycler view adapter for loading thumbnail views
Nested Classes | |||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|
enum | ThumbnailsViewAdapter.DocumentFormat | The format of document | |||||||||
interface | ThumbnailsViewAdapter.EditPagesListener | Callback interface to be invoked when pages of the document have been edited. | |||||||||
interface | ThumbnailsViewAdapter.EditPagesProgressListener |
Public Constructors | |||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|
ThumbnailsViewAdapter(Context context, ThumbnailsViewAdapter.EditPagesListener listener, FragmentManager fragmentManager, PDFViewCtrl pdfViewCtrl, List<Integer> dataList, int spanCount, ViewHolderBindListener bindListener, ThumbnailsViewFragment.Theme theme)
Class constructor
|
Public Methods | |||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|
void |
add(Integer item)
The overload implementation of
add(Object) . | ||||||||||
void | addAll(List<Integer> data) | ||||||||||
void |
addDocPages(int position, ThumbnailsViewAdapter.DocumentFormat documentFormat, Object data, String password)
Adds document pages at the specified (zero-indexed) position, or to end of file if position is -1.
| ||||||||||
void |
addDocPages(int position, ThumbnailsViewAdapter.DocumentFormat documentFormat, Object data)
Adds document pages at the specified (zero-indexed) position, or to end of file if position is -1.
| ||||||||||
void | clear() | ||||||||||
void |
clearResources()
Clears resources.
| ||||||||||
void |
duplicateDocPages(List<Integer> pageList)
Duplicates pages.
| ||||||||||
void |
finish()
Cleans up resources
| ||||||||||
int | getActivePageNumberBackgroundLabelColor() | ||||||||||
int | getCurrentPage() | ||||||||||
boolean | getDocPagesModified() | ||||||||||
Integer |
getItem(int position)
The overload implementation of
getItem(int) . | ||||||||||
int |
getItemCount()
The overload implementation of SimpleRecyclerViewAdapter#getItemCount().
| ||||||||||
int | getPageNumberBackgroundLabelColor() | ||||||||||
int | getPositionForPage(int pageNum) | ||||||||||
void |
insert(Integer item, int position)
The overload implementation of
insert(Object, int) . | ||||||||||
boolean | isEditing() | ||||||||||
void | moveDocPages(List<Integer> pageIndicesToMove, int toPosition) | ||||||||||
void |
onBindViewHolder(ThumbnailsViewAdapter.PageViewHolder holder, int position)
The overload implementation of
onBindViewHolder(RecyclerView.ViewHolder, int) . | ||||||||||
ThumbnailsViewAdapter.PageViewHolder |
onCreateViewHolder(ViewGroup parent, int viewType)
The overload implementation of SimpleRecyclerViewAdapter#onCreateViewHolder(ViewGroup, int).
| ||||||||||
void |
onDetachedFromRecyclerView(RecyclerView recyclerView)
The overload implementation of
onDetachedFromRecyclerView(RecyclerView) . | ||||||||||
void |
onItemDismiss(int position)
The overload implementation of ItemTouchHelperAdapter#onItemDismiss(int).
| ||||||||||
void |
onItemDrop(int fromPosition, int toPosition)
The overload implementation of ItemTouchHelperAdapter#onItemDrop(int, int).
| ||||||||||
boolean |
onItemMove(int fromPosition, int toPosition)
The overload implementation of ItemTouchHelperAdapter#onItemMove(int, int).
| ||||||||||
void | onItemsAdd(List<Integer> itemPositionsToAdd, int toPosition) | ||||||||||
void | onItemsDrop(List<Integer> itemPositionsToDrop, int toPosition) | ||||||||||
List<Integer> | onItemsRemove(List<Integer> fromPositions) | ||||||||||
void |
onPasswordDialogDismiss(boolean forcedDismiss)
The overload implementation of
onPasswordDialogPositiveClick(int, File, String, String, String) . | ||||||||||
void |
onPasswordDialogNegativeClick(int fileType, File file, String path)
The overload implementation of
onPasswordDialogPositiveClick(int, File, String, String, String) . | ||||||||||
void |
onPasswordDialogPositiveClick(int fileType, File file, String path, String password, String id)
The overload implementation of
onPasswordDialogPositiveClick(int, File, String, String, String) . | ||||||||||
void |
onThumbReceived(int page, int[] buf, int width, int height)
The overload implementation of
onThumbReceived(int, int[], int, int) . | ||||||||||
boolean |
remove(Integer item)
The overload implementation of
remove(Object) . | ||||||||||
Integer |
removeAt(int location)
The overload implementation of
removeAt(int) . | ||||||||||
void |
removeDocPage(int pageNum)
Removes a document page.
| ||||||||||
void |
rotateDocPage(int pageNum, boolean clockwise)
Rotates the document page.
| ||||||||||
void |
rotateDocPage(int pageNum)
Rotates the document page clockwise.
| ||||||||||
void | setActivePageNumberBackgroundLabelColor(int activePageColorInt) | ||||||||||
void |
setCurrentPage(int pageNum)
Sets the current page.
| ||||||||||
void | setData(List<Integer> data) | ||||||||||
static void | setDebug(boolean debug) | ||||||||||
void | setEditPagesProgressListener(ThumbnailsViewAdapter.EditPagesProgressListener listener) | ||||||||||
void | setEditing(boolean editing) | ||||||||||
void | setItem(int position, int data) | ||||||||||
void | setPageNumberBackgroundLabelColor(int pageColorInt) | ||||||||||
void | setPdfViewCtrl(PDFViewCtrl pdfViewCtrl) | ||||||||||
void |
updateAfterAddition(List<Integer> pageList)
Updates the adapter after pages addition.
| ||||||||||
void |
updateAfterDeletion(List<Integer> pageList)
Updates the adapter after pages deletion.
| ||||||||||
void |
updateAfterMove(int fromPageNum, int toPageNum)
Updates the adapter after page movement.
| ||||||||||
void |
updateAfterPageLabelEdit()
Updates the adapter after editing page labels.
| ||||||||||
void |
updateAfterRotation(List<Integer> pageList)
Updates the adapter after pages rotation.
| ||||||||||
void |
updateMainViewWidth(int width)
Updates the main view width
| ||||||||||
int |
updatePageNumberOnDelete(int deletedPage)
Updates the page numbers after deleting a page
| ||||||||||
void |
updateSpanCount(int count)
The overload implementation of
updateSpanCount(int) . |
[Expand]
Inherited Methods | |||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|
From class
com.pdftron.pdf.widget.recyclerview.SimpleRecyclerViewAdapter
| |||||||||||
From class
java.lang.Object
| |||||||||||
From interface
com.pdftron.pdf.PDFViewCtrl.ThumbAsyncListener
| |||||||||||
From interface
com.pdftron.pdf.controls.PasswordDialogFragment.PasswordDialogFragmentListener
|
Class constructor
Adds document pages at the specified (zero-indexed) position, or to end of file if position is -1. Lastly scroll to newly created page, if necessary
position | The position where the pages are inserted to |
---|---|
documentFormat | The document format |
data | The extra data including page(s) |
password | The document password |
Adds document pages at the specified (zero-indexed) position, or to end of file if position is -1. Lastly scroll to newly created page, if necessary
position | The position where the pages are added on |
---|---|
documentFormat | The document format |
data | The extra data including page(s) |
Clears resources.
Duplicates pages.
pageList | The list of pages to be duplicated |
---|
Cleans up resources
The overload implementation of SimpleRecyclerViewAdapter#getItemCount().
The overload implementation of insert(Object, int)
.
item | The item |
---|---|
position | The position |
The overload implementation of onBindViewHolder(RecyclerView.ViewHolder, int)
.
The overload implementation of SimpleRecyclerViewAdapter#onCreateViewHolder(ViewGroup, int).
The overload implementation of onDetachedFromRecyclerView(RecyclerView)
.
The overload implementation of ItemTouchHelperAdapter#onItemDismiss(int).
The overload implementation of ItemTouchHelperAdapter#onItemDrop(int, int).
The overload implementation of ItemTouchHelperAdapter#onItemMove(int, int).
The overload implementation of onPasswordDialogPositiveClick(int, File, String, String, String)
.
forcedDismiss | True if the dialog is forced to dismiss |
---|
The overload implementation of onPasswordDialogPositiveClick(int, File, String, String, String)
.
fileType | The file type |
---|---|
file | The file |
path | The file path |
The overload implementation of onPasswordDialogPositiveClick(int, File, String, String, String)
.
fileType | The file type |
---|---|
file | The file |
path | The file path |
password | The entered password |
id | The ID |
The overload implementation of onThumbReceived(int, int[], int, int)
.
page | the page number which this thumbnail refers to |
---|---|
buf | the image data buffer |
width | the width of the bitmap |
height | the height of the bitmap |
The overload implementation of remove(Object)
.
item | The item |
---|
The overload implementation of removeAt(int)
.
location | The position |
---|
Removes a document page.
pageNum | The page number to be removed |
---|
Rotates the document page.
pageNum | The page number to be rotated |
---|---|
clockwise | Direction of the rotation |
Rotates the document page clockwise.
pageNum | The page number to be rotated |
---|
Sets the current page.
pageNum | The page number to be set as the current |
---|
Updates the adapter after pages addition.
pageList | The list of pages added to the document |
---|
Updates the adapter after pages deletion.
pageList | The list of pages removed from the document |
---|
Updates the adapter after page movement.
fromPageNum | The page number from which the page was moved |
---|---|
toPageNum | The page number to which the page was moved |
Updates the adapter after editing page labels.
Updates the adapter after pages rotation.
pageList | The list of rotated pages |
---|
Updates the main view width
width | The width |
---|
Updates the page numbers after deleting a page
deletedPage | The page number of the page deleted |
---|
The overload implementation of updateSpanCount(int)
.
count | The span count |
---|