-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
bc2acd6
commit 810d1f5
Showing
7 changed files
with
18 additions
and
16 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,5 +1,5 @@ | ||
/* | ||
Copyright 2012-2022 Michael Pozhidaev <[email protected]> | ||
Copyright 2012-2023 Michael Pozhidaev <[email protected]> | ||
This file is part of LUWRAIN. | ||
|
@@ -71,8 +71,8 @@ public App(String arg) | |
private ViewPdf createPdfView(File file) throws IOException | ||
{ | ||
return new ViewPdf(getLuwrain(), file){ | ||
@Override void inaccessible() { getLuwrain().playSound(Sounds.ERROR); } | ||
@Override void announcePage(int pageNum, int pageCount) { message("Страница " + pageNum, Luwrain.MessageType.OK); } | ||
@Override void inaccessible() { getLuwrain().playSound(Sounds.EVENT_NOT_PROCESSED); } | ||
@Override void announcePage(int pageNum, int pageCount) { message(getStrings().pdfPage(String.valueOf(pageNum), String.valueOf(pageCount)), Luwrain.MessageType.OK); } | ||
@Override void announceMoveLeft() {} | ||
@Override void announceMoveRight() {} | ||
@Override void announceMoveUp() {} | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,5 +1,5 @@ | ||
/* | ||
Copyright 2012-2022 Michael Pozhidaev <[email protected]> | ||
Copyright 2012-2023 Michael Pozhidaev <[email protected]> | ||
This file is part of LUWRAIN. | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,5 +1,5 @@ | ||
/* | ||
Copyright 2012-2022 Michael Pozhidaev <[email protected]> | ||
Copyright 2012-2023 Michael Pozhidaev <[email protected]> | ||
This file is part of LUWRAIN. | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,5 +1,5 @@ | ||
/* | ||
Copyright 2012-2022 Michael Pozhidaev <[email protected]> | ||
Copyright 2012-2023 Michael Pozhidaev <[email protected]> | ||
This file is part of LUWRAIN. | ||
|
@@ -22,4 +22,5 @@ public interface Strings | |
NAME = "luwrain.viewer"; | ||
|
||
String appName(); | ||
} | ||
String pdfPage(String pageNum, String pageCount); | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,5 +1,5 @@ | ||
/* | ||
Copyright 2012-2022 Michael Pozhidaev <[email protected]> | ||
Copyright 2012-2023 Michael Pozhidaev <[email protected]> | ||
This file is part of LUWRAIN. | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,5 +1,5 @@ | ||
/* | ||
Copyright 2012-2022 Michael Pozhidaev <[email protected]> | ||
Copyright 2012-2023 Michael Pozhidaev <[email protected]> | ||
This file is part of LUWRAIN. | ||
|
@@ -182,7 +182,7 @@ public void close() | |
}); | ||
} | ||
|
||
public boolean showPage(int index) | ||
private boolean showPage(int index) | ||
{ | ||
if (index < 0 || index >= getPageCount()) | ||
return false; | ||
|
@@ -193,7 +193,7 @@ public boolean showPage(int index) | |
return false; | ||
} | ||
|
||
int getPageCount() | ||
private int getPageCount() | ||
{ | ||
return doc.getNumberOfPages(); | ||
} | ||
|
@@ -304,16 +304,16 @@ private void onKey(Interaction.GraphicalModeControl graphicalModeControl, KeyEve | |
graphicalModeControl.close(); | ||
break; | ||
case PAGE_DOWN: | ||
// listener.onInputEvent(new InputEvent(InputEvent.Special.PAGE_DOWN)); | ||
break; | ||
nextPage(); | ||
break; | ||
case PAGE_UP: | ||
// listener.onInputEvent(new InputEvent(InputEvent.Special.PAGE_UP)); | ||
prevPage(); | ||
break; | ||
case HOME: | ||
// listener.onInputEvent(new InputEvent(InputEvent.Special.HOME)); | ||
showPage(0); | ||
break; | ||
case END: | ||
// listener.onInputEvent(new InputEvent(InputEvent.Special.END)); | ||
showPage(getPageCount() - 1); | ||
break; | ||
case DOWN: | ||
// listener.onInputEvent(new InputEvent(InputEvent.Special.ARROW_DOWN)); | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,2 +1,3 @@ | ||
|
||
AppName = Графический просмотр | ||
PdfPage = Страница $1 из $2 |