summaryrefslogtreecommitdiff
path: root/platform
diff options
context:
space:
mode:
Diffstat (limited to 'platform')
-rw-r--r--platform/android/example/app/src/main/res/layout/activity_doc_view.xml16
-rw-r--r--platform/android/example/app/src/main/res/layout/activity_main.xml7
-rw-r--r--platform/android/example/app/src/main/res/layout/choose_doc.xml48
-rw-r--r--platform/android/example/app/src/main/res/layout/picker_entry.xml38
-rw-r--r--platform/android/example/app/src/main/res/values/colors.xml2
-rw-r--r--platform/android/example/app/src/main/res/values/styles.xml10
-rw-r--r--platform/android/example/mupdf/src/main/AndroidManifest.xml24
-rw-r--r--platform/android/example/mupdf/src/main/res/values/strings.xml2
-rw-r--r--platform/android/viewer/AndroidManifest.xml4
-rw-r--r--platform/android/viewer/ClassStructure.txt5
-rw-r--r--platform/android/viewer/ReadMe.txt4
-rw-r--r--platform/android/viewer/build.gradle109
-rw-r--r--platform/android/viewer/build.xml151
-rw-r--r--platform/android/viewer/jni/Android.mk6
-rw-r--r--platform/android/viewer/jni/Core.mk6
-rw-r--r--platform/android/viewer/res/values/styles.xml6
-rw-r--r--platform/android/viewer/src/com/artifex/mupdfdemo/ChoosePDFActivity.java1
-rw-r--r--platform/android/viewer/src/com/artifex/mupdfdemo/Deque.java2
-rw-r--r--platform/android/viewer/src/com/artifex/mupdfdemo/MuPDFPageView.java1
-rw-r--r--platform/android/viewer/src/com/artifex/mupdfdemo/PageView.java1
-rw-r--r--platform/android/viewer/src/com/artifex/mupdfdemo/ReaderView.java2
-rw-r--r--platform/java/example/PageCanvas.java4
-rw-r--r--platform/java/example/TraceDevice.java2
-rw-r--r--platform/java/example/Viewer.java6
-rw-r--r--platform/win32/libmupdf.vcproj6
25 files changed, 216 insertions, 247 deletions
diff --git a/platform/android/example/app/src/main/res/layout/activity_doc_view.xml b/platform/android/example/app/src/main/res/layout/activity_doc_view.xml
index 7f5ece24..36761615 100644
--- a/platform/android/example/app/src/main/res/layout/activity_doc_view.xml
+++ b/platform/android/example/app/src/main/res/layout/activity_doc_view.xml
@@ -1,13 +1,13 @@
<?xml version="1.0" encoding="utf-8"?>
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
- android:layout_width="match_parent"
- android:layout_height="match_parent"
- android:orientation="vertical">
+ android:layout_width="match_parent"
+ android:layout_height="match_parent"
+ android:orientation="vertical">
- <com.artifex.mupdf.android.DocView
- android:id="@+id/doc_view"
- android:layout_width="match_parent"
- android:layout_height="match_parent">
- </com.artifex.mupdf.android.DocView>
+ <com.artifex.mupdf.android.DocView
+ android:id="@+id/doc_view"
+ android:layout_width="match_parent"
+ android:layout_height="match_parent">
+ </com.artifex.mupdf.android.DocView>
</LinearLayout>
diff --git a/platform/android/example/app/src/main/res/layout/activity_main.xml b/platform/android/example/app/src/main/res/layout/activity_main.xml
index 24f3d6ba..3d1efc88 100644
--- a/platform/android/example/app/src/main/res/layout/activity_main.xml
+++ b/platform/android/example/app/src/main/res/layout/activity_main.xml
@@ -1,6 +1,5 @@
<?xml version="1.0" encoding="utf-8"?>
<RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android"
- android:layout_width="match_parent"
- android:layout_height="match_parent">
-
-</RelativeLayout> \ No newline at end of file
+ android:layout_width="match_parent"
+ android:layout_height="match_parent">
+</RelativeLayout>
diff --git a/platform/android/example/app/src/main/res/layout/choose_doc.xml b/platform/android/example/app/src/main/res/layout/choose_doc.xml
index 48e63b8c..bbccc496 100644
--- a/platform/android/example/app/src/main/res/layout/choose_doc.xml
+++ b/platform/android/example/app/src/main/res/layout/choose_doc.xml
@@ -1,32 +1,30 @@
<?xml version="1.0" encoding="utf-8"?>
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
- android:layout_width="match_parent"
- android:layout_height="match_parent">
+ android:layout_width="match_parent"
+ android:layout_height="match_parent">
- <LinearLayout
- android:orientation="vertical"
- android:layout_width="match_parent"
- android:layout_height="match_parent"
- android:layout_gravity="center_horizontal"
- android:id="@+id/device_files_wrapper">
+ <LinearLayout
+ android:orientation="vertical"
+ android:layout_width="match_parent"
+ android:layout_height="match_parent"
+ android:layout_gravity="center_horizontal"
+ android:id="@+id/device_files_wrapper">
- <LinearLayout
- android:orientation="vertical"
- android:layout_width="match_parent"
- android:layout_height="match_parent"
- android:layout_gravity="center_horizontal"
- android:id="@+id/file_list_wrpper">
+ <LinearLayout
+ android:orientation="vertical"
+ android:layout_width="match_parent"
+ android:layout_height="match_parent"
+ android:layout_gravity="center_horizontal"
+ android:id="@+id/file_list_wrpper">
- <ListView
- android:layout_width="match_parent"
- android:layout_height="wrap_content"
- android:id="@+id/fileListView"
- android:layout_gravity="center_horizontal"
- android:choiceMode="singleChoice"
- android:background="#ffffff"/>
-
- </LinearLayout>
-
- </LinearLayout>
+ <ListView
+ android:layout_width="match_parent"
+ android:layout_height="wrap_content"
+ android:id="@+id/fileListView"
+ android:layout_gravity="center_horizontal"
+ android:choiceMode="singleChoice"
+ android:background="#ffffff"/>
+ </LinearLayout>
+ </LinearLayout>
</LinearLayout>
diff --git a/platform/android/example/app/src/main/res/layout/picker_entry.xml b/platform/android/example/app/src/main/res/layout/picker_entry.xml
index 98ede7d6..5dead12f 100644
--- a/platform/android/example/app/src/main/res/layout/picker_entry.xml
+++ b/platform/android/example/app/src/main/res/layout/picker_entry.xml
@@ -1,25 +1,25 @@
<?xml version="1.0" encoding="utf-8"?>
<RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android"
- android:layout_width="match_parent"
- android:layout_height="wrap_content"
- android:paddingLeft="4dp" >
+ android:layout_width="match_parent"
+ android:layout_height="wrap_content"
+ android:paddingLeft="4dp" >
- <ImageView
- android:id="@+id/icon"
- android:layout_width="wrap_content"
- android:layout_height="wrap_content"
- android:layout_centerVertical="true"
- android:layout_alignParentLeft="true" />
+ <ImageView
+ android:id="@+id/icon"
+ android:layout_width="wrap_content"
+ android:layout_height="wrap_content"
+ android:layout_centerVertical="true"
+ android:layout_alignParentLeft="true" />
- <TextView
- android:id="@+id/name"
- android:layout_width="match_parent"
- android:layout_height="wrap_content"
- android:layout_toRightOf="@+id/icon"
- android:paddingBottom="4dp"
- android:paddingLeft="10dp"
- android:paddingRight="4dp"
- android:paddingTop="4dp"
- android:textAppearance="?android:attr/textAppearanceMedium" />
+ <TextView
+ android:id="@+id/name"
+ android:layout_width="match_parent"
+ android:layout_height="wrap_content"
+ android:layout_toRightOf="@+id/icon"
+ android:paddingBottom="4dp"
+ android:paddingLeft="10dp"
+ android:paddingRight="4dp"
+ android:paddingTop="4dp"
+ android:textAppearance="?android:attr/textAppearanceMedium" />
</RelativeLayout>
diff --git a/platform/android/example/app/src/main/res/values/colors.xml b/platform/android/example/app/src/main/res/values/colors.xml
index b8acf28a..47c6eb22 100644
--- a/platform/android/example/app/src/main/res/values/colors.xml
+++ b/platform/android/example/app/src/main/res/values/colors.xml
@@ -1,4 +1,4 @@
<?xml version="1.0" encoding="utf-8"?>
<resources>
- <color name="white">#FFFFFFFF</color>
+ <color name="white">#FFFFFFFF</color>
</resources>
diff --git a/platform/android/example/app/src/main/res/values/styles.xml b/platform/android/example/app/src/main/res/values/styles.xml
index 3d804574..97e54a45 100644
--- a/platform/android/example/app/src/main/res/values/styles.xml
+++ b/platform/android/example/app/src/main/res/values/styles.xml
@@ -1,8 +1,6 @@
<?xml version="1.0" encoding="utf-8"?>
<resources>
-
- <!-- Base application theme. -->
- <style name="AppBaseTheme" parent="@android:style/Theme.NoTitleBar.Fullscreen">
- </style>
-
-</resources> \ No newline at end of file
+ <!-- Base application theme. -->
+ <style name="AppBaseTheme" parent="@android:style/Theme.NoTitleBar.Fullscreen">
+ </style>
+</resources>
diff --git a/platform/android/example/mupdf/src/main/AndroidManifest.xml b/platform/android/example/mupdf/src/main/AndroidManifest.xml
index af5dbc58..4065d7fd 100644
--- a/platform/android/example/mupdf/src/main/AndroidManifest.xml
+++ b/platform/android/example/mupdf/src/main/AndroidManifest.xml
@@ -1,16 +1,10 @@
-<manifest package="com.artifex.mupdf.mupdf"
- xmlns:android="http://schemas.android.com/apk/res/android">
-
- package="com.artifex.mupdf.fitz">
- <uses-permission android:name="android.permission.WRITE_EXTERNAL_STORAGE" />
- <uses-permission android:name="android.permission.READ_EXTERNAL_STORAGE" />
- <uses-permission android:name="android.permission.INTERNET" />
-
- <application android:allowBackup="true"
- android:label="@string/app_name"
- android:supportsRtl="true"
- >
-
- </application>
-
+<manifest package="com.artifex.mupdf.fitz" xmlns:android="http://schemas.android.com/apk/res/android">
+ <uses-permission android:name="android.permission.WRITE_EXTERNAL_STORAGE" />
+ <uses-permission android:name="android.permission.READ_EXTERNAL_STORAGE" />
+ <uses-permission android:name="android.permission.INTERNET" />
+ <application android:allowBackup="true"
+ android:label="@string/app_name"
+ android:supportsRtl="true"
+ >
+ </application>
</manifest>
diff --git a/platform/android/example/mupdf/src/main/res/values/strings.xml b/platform/android/example/mupdf/src/main/res/values/strings.xml
index 0f541156..28af5d41 100644
--- a/platform/android/example/mupdf/src/main/res/values/strings.xml
+++ b/platform/android/example/mupdf/src/main/res/values/strings.xml
@@ -1,3 +1,3 @@
<resources>
- <string name="app_name">mupdf</string>
+ <string name="app_name">mupdf</string>
</resources>
diff --git a/platform/android/viewer/AndroidManifest.xml b/platform/android/viewer/AndroidManifest.xml
index 29c20f84..78dcce1d 100644
--- a/platform/android/viewer/AndroidManifest.xml
+++ b/platform/android/viewer/AndroidManifest.xml
@@ -3,7 +3,7 @@
package="com.artifex.mupdfdemo"
android:versionCode="50"
android:versionName="@string/version"
- android:debuggable="false"
+ android:debuggable="false"
android:installLocation="auto">
<uses-permission android:name="android.permission.WRITE_EXTERNAL_STORAGE" />
<uses-permission android:name="android.permission.INTERNET" />
@@ -99,4 +99,4 @@
android:label="@string/print">
</activity>
</application>
-</manifest>
+</manifest>
diff --git a/platform/android/viewer/ClassStructure.txt b/platform/android/viewer/ClassStructure.txt
index 39939674..ff1f9409 100644
--- a/platform/android/viewer/ClassStructure.txt
+++ b/platform/android/viewer/ClassStructure.txt
@@ -5,7 +5,6 @@ MuPDFActivity is the main activity used when displaying and interacting with a
document. This class is responsible for creating the view hierarchy and the
menus.
-
Main view classes
~~~~~~~~~~~~~~~~~
@@ -83,7 +82,6 @@ appearances, can take on their correct size immediately. (The determining of
page size is not a completely trivial operation and is performed on a
background thread, as is all interaction with the core MuPDF library).
-
C library wrapper
~~~~~~~~~~~~~~~~~
@@ -98,7 +96,6 @@ and because even the fast methods have to be synchronised with the slower
methods, (almost) all methods should be called in the background. There are a
few non synchronised ones that have special purposes.
-
Link handling
~~~~~~~~~~~~~
There are three types of PDF links, each entailing different information and
@@ -178,10 +175,8 @@ PrintDialogActivity
~~~~~~~~~~~~~~~~~~~
This activity allows the user to print documents via Google Cloud Print.
-
Copied system classes
~~~~~~~~~~~~~~~~~~~~~
AsyncTask has had improvements made to it since issuing at the lowest android
API level we support, and so we include the improved version as part of the
MuPDF app. We also include Deque and ArrayDeque, which are used my AsyncTask.
-
diff --git a/platform/android/viewer/ReadMe.txt b/platform/android/viewer/ReadMe.txt
index 550d16dc..b2e5eb1e 100644
--- a/platform/android/viewer/ReadMe.txt
+++ b/platform/android/viewer/ReadMe.txt
@@ -20,11 +20,11 @@ will show you the install location.
The Android Studio SDK unpacked as:
- C:\Users\UserName\AppData\Local\Android\sdk
+ C:\Users\UserName\AppData\Local\Android\sdk
on Windows. On MacOS it installed in:
- /Users/UserName/Library/Android/sdk
+ /Users/UserName/Library/Android/sdk
In the 'SDK Plaforms' tab, ensure that at least API 16 is
downloaded. I have a selection of later APIs too (17, 19, 22),
diff --git a/platform/android/viewer/build.gradle b/platform/android/viewer/build.gradle
index 1bd5313b..1736e939 100644
--- a/platform/android/viewer/build.gradle
+++ b/platform/android/viewer/build.gradle
@@ -1,89 +1,86 @@
import org.apache.tools.ant.taskdefs.condition.Os
buildscript {
- repositories {
- jcenter()
- }
- dependencies {
- classpath 'com.android.tools.build:gradle:1.2.3'
- }
+ repositories {
+ jcenter()
+ }
+ dependencies {
+ classpath 'com.android.tools.build:gradle:1.2.3'
+ }
}
allprojects {
- repositories {
- jcenter()
- }
+ repositories {
+ jcenter()
+ }
}
apply plugin: 'com.android.application'
dependencies {
- compile fileTree(dir: 'libs', include: '*.so')
+ compile fileTree(dir: 'libs', include: '*.so')
}
android {
+ compileSdkVersion 17
+ buildToolsVersion '21.1.2'
- compileSdkVersion 17
- buildToolsVersion '21.1.2'
-
- /* this stops gradle from making it's own Android.mk file */
+ /* this stops gradle from making it's own Android.mk file */
sourceSets.main.jni.srcDirs = []
-
- sourceSets {
- main {
- manifest {
- srcFile 'AndroidManifest.xml'
- }
- java {
- srcDir 'src'
- exclude 'com/artifex/mupdf/fitz/AndroidDrawDevice.java'
- }
- res {
- srcDir 'res'
- }
- assets {
- srcDir 'assets'
- }
- resources {
- srcDir 'src'
- }
- jniLibs {
- srcDir 'libs'
- }
- }
- }
- /* This is important, it will run lint checks but won't abort build */
- lintOptions {
- abortOnError false
- }
-
+ sourceSets {
+ main {
+ manifest {
+ srcFile 'AndroidManifest.xml'
+ }
+ java {
+ srcDir 'src'
+ exclude 'com/artifex/mupdf/fitz/AndroidDrawDevice.java'
+ }
+ res {
+ srcDir 'res'
+ }
+ assets {
+ srcDir 'assets'
+ }
+ resources {
+ srcDir 'src'
+ }
+ jniLibs {
+ srcDir 'libs'
+ }
+ }
+ }
+
+ /* This is important, it will run lint checks but won't abort build */
+ lintOptions {
+ abortOnError false
+ }
}
-/* This defines the path to Android's ndk-build. */
+/* This defines the path to Android's ndk-build. */
def ndkBuildPath = plugins.getPlugin('com.android.application').sdkHandler.getNdkFolder().absolutePath + File.separator + 'ndk-build'
if (Os.isFamily(Os.FAMILY_WINDOWS)) {
- ndkBuildPath +='.cmd'
+ ndkBuildPath +='.cmd'
}
-/* This task builds the native part */
+/* This task builds the native part */
task buildNative(type: Exec,description: 'Compile JNI source via NDK') {
- println('executing buildNative')
- commandLine ndkBuildPath, '-C', file('.').absolutePath, ' FZ_ENABLE_GPRF=1'
- //'NDK_PROJECT_PATH=build','APP_BUILD_SCRIPT=src/main/jni/Android.mk'//force using appropriate Makefile
+ println('executing buildNative')
+ commandLine ndkBuildPath, '-C', file('.').absolutePath, ' FZ_ENABLE_GPRF=1'
+ //'NDK_PROJECT_PATH=build','APP_BUILD_SCRIPT=src/main/jni/Android.mk'//force using appropriate Makefile
}
-/* This task cleans the native part */
+/* This task cleans the native part */
task cleanNative(type: Exec, description: 'Clean JNI object files') {
- println('executing cleanNative')
- commandLine ndkBuildPath, '-C', file('.').absolutePath, 'clean'
+ println('executing cleanNative')
+ commandLine ndkBuildPath, '-C', file('.').absolutePath, 'clean'
}
-/* cleaning should also include cleaning native */
+/* cleaning should also include cleaning native */
clean.dependsOn 'cleanNative'
-/* building should include native */
+/* building should include native */
tasks.withType(JavaCompile){
- compileTask -> compileTask.dependsOn buildNative
+ compileTask -> compileTask.dependsOn buildNative
}
-
diff --git a/platform/android/viewer/build.xml b/platform/android/viewer/build.xml
index 7cb2cdf8..627346bc 100644
--- a/platform/android/viewer/build.xml
+++ b/platform/android/viewer/build.xml
@@ -1,85 +1,82 @@
<?xml version="1.0" encoding="UTF-8"?>
<project name="MuPDF" default="help">
- <!-- The local.properties file is created and updated by the 'android' tool.
- It contains the path to the SDK. It should *NOT* be checked into
- Version Control Systems. -->
- <loadproperties srcFile="local.properties" />
-
- <!-- The ant.properties file can be created by you. It is only edited by the
- 'android' tool to add properties to it.
- This is the place to change some Ant specific build properties.
- Here are some properties you may want to change/update:
-
- source.dir
- The name of the source directory. Default is 'src'.
- out.dir
- The name of the output directory. Default is 'bin'.
-
- For other overridable properties, look at the beginning of the rules
- files in the SDK, at tools/ant/build.xml
-
- Properties related to the SDK location or the project target should
- be updated using the 'android' tool with the 'update' action.
-
- This file is an integral part of the build system for your
- application and should be checked into Version Control Systems.
-
- -->
- <property file="ant.properties" />
-
- <!-- The project.properties file is created and updated by the 'android'
- tool, as well as ADT.
-
- This contains project specific properties such as project target, and library
- dependencies. Lower level build properties are stored in ant.properties
- (or in .classpath for Eclipse projects).
-
- This file is an integral part of the build system for your
- application and should be checked into Version Control Systems. -->
- <loadproperties srcFile="project.properties" />
-
- <!-- quick check on sdk.dir -->
- <fail
- message="sdk.dir is missing. Make sure to generate local.properties using 'android update project'"
- unless="sdk.dir"
- />
-
-
-<!-- extension targets. Uncomment the ones where you want to do custom work
- in between standard targets -->
+ <!--
+ The local.properties file is created and updated by the 'android' tool.
+ It contains the path to the SDK. It should *NOT* be checked into
+ Version Control Systems.
+ -->
+ <loadproperties srcFile="local.properties" />
+
+ <!--
+ The ant.properties file can be created by you. It is only edited by the
+ 'android' tool to add properties to it.
+ This is the place to change some Ant specific build properties.
+ Here are some properties you may want to change/update:
+
+ source.dir
+ The name of the source directory. Default is 'src'.
+ out.dir
+ The name of the output directory. Default is 'bin'.
+
+ For other overridable properties, look at the beginning of the rules
+ files in the SDK, at tools/ant/build.xml
+
+ Properties related to the SDK location or the project target should
+ be updated using the 'android' tool with the 'update' action.
+
+ This file is an integral part of the build system for your
+ application and should be checked into Version Control Systems.
+ -->
+ <property file="ant.properties" />
+
+ <!--
+ The project.properties file is created and updated by the 'android'
+ tool, as well as ADT.
+
+ This contains project specific properties such as project target, and library
+ dependencies. Lower level build properties are stored in ant.properties
+ (or in .classpath for Eclipse projects).
+
+ This file is an integral part of the build system for your
+ application and should be checked into Version Control Systems.
+ -->
+ <loadproperties srcFile="project.properties" />
+
+ <!-- quick check on sdk.dir -->
+ <fail
+ message="sdk.dir is missing. Make sure to generate local.properties using 'android update project'"
+ unless="sdk.dir"
+ />
+
+<!-- extension targets. Uncomment the ones where you want to do custom work in between standard targets -->
<!--
- <target name="-pre-build">
- </target>
- <target name="-pre-compile">
- </target>
-
- /* This is typically used for code obfuscation.
- Compiled code location: ${out.classes.absolute.dir}
- If this is not done in place, override ${out.dex.input.absolute.dir} */
- <target name="-post-compile">
- </target>
+ <target name="-pre-build">
+ </target>
+ <target name="-pre-compile">
+ </target>
+ <target name="-post-compile">
+ </target>
-->
- <!-- Import the actual build file.
-
- To customize existing targets, there are two options:
- - Customize only one target:
- - copy/paste the target into this file, *before* the
- <import> task.
- - customize it to your needs.
- - Customize the whole content of build.xml
- - copy/paste the content of the rules files (minus the top node)
- into this file, replacing the <import> task.
- - customize to your needs.
-
- ***********************
- ****** IMPORTANT ******
- ***********************
- In all cases you must update the value of version-tag below to read 'custom' instead of an integer,
- in order to avoid having your file be overridden by tools such as "android update project"
- -->
- <!-- version-tag: 1 -->
- <import file="${sdk.dir}/tools/ant/build.xml" />
+ <!-- Import the actual build file.
+
+ To customize existing targets, there are two options:
+ - Customize only one target:
+ - copy/paste the target into this file, *before* the <import> task.
+ - customize it to your needs.
+ - Customize the whole content of build.xml
+ - copy/paste the content of the rules files (minus the top node)
+ into this file, replacing the <import> task.
+ - customize to your needs.
+
+ ***********************
+ ****** IMPORTANT ******
+ ***********************
+ In all cases you must update the value of version-tag below to read 'custom' instead of an integer,
+ in order to avoid having your file be overridden by tools such as "android update project"
+ -->
+ <!-- version-tag: 1 -->
+ <import file="${sdk.dir}/tools/ant/build.xml" />
</project>
diff --git a/platform/android/viewer/jni/Android.mk b/platform/android/viewer/jni/Android.mk
index 2f5adf48..0a1dbf38 100644
--- a/platform/android/viewer/jni/Android.mk
+++ b/platform/android/viewer/jni/Android.mk
@@ -19,7 +19,7 @@ LOCAL_C_INCLUDES := \
$(MUPDF_ROOT)/source/pdf \
$(MUPDF_ROOT)/platform/java
LOCAL_CFLAGS := -DHAVE_ANDROID
-LOCAL_MODULE := mupdf_java
+LOCAL_MODULE := mupdf_java
LOCAL_SRC_FILES := \
mupdf.c \
@@ -34,9 +34,9 @@ ifdef SUPPORT_GPROOF
LOCAL_CFLAGS += -DSUPPORT_GPROOF
endif
-LOCAL_LDLIBS := -lm -llog -ljnigraphics
+LOCAL_LDLIBS := -lm -llog -ljnigraphics
ifdef SSL_BUILD
-LOCAL_LDLIBS += -L$(MUPDF_ROOT)/thirdparty/openssl/android -lcrypto -lssl
+LOCAL_LDLIBS += -L$(MUPDF_ROOT)/thirdparty/openssl/android -lcrypto -lssl
endif
include $(BUILD_SHARED_LIBRARY)
diff --git a/platform/android/viewer/jni/Core.mk b/platform/android/viewer/jni/Core.mk
index 7371a33d..7a0913b4 100644
--- a/platform/android/viewer/jni/Core.mk
+++ b/platform/android/viewer/jni/Core.mk
@@ -2,7 +2,7 @@ LOCAL_PATH := $(call my-dir)
ifdef SUPPORT_GPROOF
include $(CLEAR_VARS)
-LOCAL_MODULE := gsso
+LOCAL_MODULE := gsso
LOCAL_SRC_FILES := libgs.so
include $(PREBUILT_SHARED_LIBRARY)
endif
@@ -58,7 +58,7 @@ ifdef SSL_BUILD
LOCAL_C_INCLUDES += $(MY_ROOT)/thirdparty/openssl/include
endif
-LOCAL_MODULE := mupdfcore
+LOCAL_MODULE := mupdfcore
LOCAL_SRC_FILES := \
$(wildcard $(MY_ROOT)/source/fitz/*.c) \
$(wildcard $(MY_ROOT)/source/pdf/*.c) \
@@ -72,7 +72,7 @@ LOCAL_SRC_FILES := \
ifdef SUPPORT_GPROOF
LOCAL_SHARED_LIBRARIES := gsso
endif
-LOCAL_LDLIBS := -lm -llog -ljnigraphics
+LOCAL_LDLIBS := -lm -llog -ljnigraphics
LOCAL_SRC_FILES := $(addprefix ../, $(LOCAL_SRC_FILES))
diff --git a/platform/android/viewer/res/values/styles.xml b/platform/android/viewer/res/values/styles.xml
index ade851dd..e1d118a9 100644
--- a/platform/android/viewer/res/values/styles.xml
+++ b/platform/android/viewer/res/values/styles.xml
@@ -1,5 +1,5 @@
<resources>
- <style name="AppBaseTheme" parent="@android:style/Theme.NoTitleBar.Fullscreen">
- <item name="android:windowBackground">@drawable/tiled_background</item>
- </style>
+ <style name="AppBaseTheme" parent="@android:style/Theme.NoTitleBar.Fullscreen">
+ <item name="android:windowBackground">@drawable/tiled_background</item>
+ </style>
</resources>
diff --git a/platform/android/viewer/src/com/artifex/mupdfdemo/ChoosePDFActivity.java b/platform/android/viewer/src/com/artifex/mupdfdemo/ChoosePDFActivity.java
index f6068bac..ca384015 100644
--- a/platform/android/viewer/src/com/artifex/mupdfdemo/ChoosePDFActivity.java
+++ b/platform/android/viewer/src/com/artifex/mupdfdemo/ChoosePDFActivity.java
@@ -44,7 +44,6 @@ public class ChoosePDFActivity extends ListActivity {
mPurpose = PICK_KEY_FILE.equals(getIntent().getAction()) ? Purpose.PickKeyFile : Purpose.PickPDF;
-
String storageState = Environment.getExternalStorageState();
if (!Environment.MEDIA_MOUNTED.equals(storageState)
diff --git a/platform/android/viewer/src/com/artifex/mupdfdemo/Deque.java b/platform/android/viewer/src/com/artifex/mupdfdemo/Deque.java
index 4bb176b2..ad17bcc0 100644
--- a/platform/android/viewer/src/com/artifex/mupdfdemo/Deque.java
+++ b/platform/android/viewer/src/com/artifex/mupdfdemo/Deque.java
@@ -452,7 +452,6 @@ public interface Deque<E> extends Queue<E> {
*/
E peek();
-
// *** Stack methods ***
/**
@@ -488,7 +487,6 @@ public interface Deque<E> extends Queue<E> {
*/
E pop();
-
// *** Collection methods ***
/**
diff --git a/platform/android/viewer/src/com/artifex/mupdfdemo/MuPDFPageView.java b/platform/android/viewer/src/com/artifex/mupdfdemo/MuPDFPageView.java
index ff6b6bbb..bca0254f 100644
--- a/platform/android/viewer/src/com/artifex/mupdfdemo/MuPDFPageView.java
+++ b/platform/android/viewer/src/com/artifex/mupdfdemo/MuPDFPageView.java
@@ -553,7 +553,6 @@ public class MuPDFPageView extends PageView implements MuPDFView {
return true;
}
-
@Override
protected CancellableTaskDefinition<Void, Void> getDrawPageTask(final Bitmap bm, final int sizeX, final int sizeY,
final int patchX, final int patchY, final int patchWidth, final int patchHeight) {
diff --git a/platform/android/viewer/src/com/artifex/mupdfdemo/PageView.java b/platform/android/viewer/src/com/artifex/mupdfdemo/PageView.java
index 2ee407cb..c897f414 100644
--- a/platform/android/viewer/src/com/artifex/mupdfdemo/PageView.java
+++ b/platform/android/viewer/src/com/artifex/mupdfdemo/PageView.java
@@ -656,7 +656,6 @@ public abstract class PageView extends ViewGroup {
mDrawPatch = null;
}
-
// Render the page in the background
mDrawEntire = new CancellableAsyncTask<Void, Void>(getUpdatePageTask(mEntireBm, mSize.x, mSize.y, 0, 0, mSize.x, mSize.y)) {
diff --git a/platform/android/viewer/src/com/artifex/mupdfdemo/ReaderView.java b/platform/android/viewer/src/com/artifex/mupdfdemo/ReaderView.java
index 65d8f665..f91efa41 100644
--- a/platform/android/viewer/src/com/artifex/mupdfdemo/ReaderView.java
+++ b/platform/android/viewer/src/com/artifex/mupdfdemo/ReaderView.java
@@ -80,7 +80,7 @@ public class ReaderView
public ReaderView(Context context, AttributeSet attrs) {
super(context, attrs);
-
+
// "Edit mode" means when the View is being displayed in the Android GUI editor. (this class
// is instantiated in the IDE, so we need to be a bit careful what we do).
if (isInEditMode())
diff --git a/platform/java/example/PageCanvas.java b/platform/java/example/PageCanvas.java
index bfeca21b..29f98a18 100644
--- a/platform/java/example/PageCanvas.java
+++ b/platform/java/example/PageCanvas.java
@@ -73,8 +73,8 @@ public class PageCanvas extends java.awt.Canvas
}
public void zoomOut() {
- mScale -= 0.25f;
- run();
+ mScale -= 0.25f;
+ run();
}
public void paint(Graphics g)
diff --git a/platform/java/example/TraceDevice.java b/platform/java/example/TraceDevice.java
index 49c97532..01e7b6c8 100644
--- a/platform/java/example/TraceDevice.java
+++ b/platform/java/example/TraceDevice.java
@@ -34,7 +34,7 @@ public class TraceDevice extends Device implements PathWalker, TextWalker
}
public void showGlyph(Font font, Matrix trm, int glyph, int unicode, boolean wmode) {
- System.out.println("glyph '" + (char)unicode + "' " + glyph + "\t" + font + " " + trm);
+ System.out.println("glyph '" + (char)unicode + "' " + glyph + "\t" + font + " " + trm);
}
public void tracePath(Path path) {
diff --git a/platform/java/example/Viewer.java b/platform/java/example/Viewer.java
index 310aeb15..c158c42d 100644
--- a/platform/java/example/Viewer.java
+++ b/platform/java/example/Viewer.java
@@ -39,7 +39,7 @@ public class Viewer extends Frame implements WindowListener, ActionListener
super("MuPDF");
retinaScale = getRetinaScale();
-
+
this.doc = doc_;
pageCount = doc.countPages();
@@ -228,7 +228,7 @@ public class Viewer extends Frame implements WindowListener, ActionListener
public float getRetinaScale()
{
- // first try Oracle's VM (we should also test for 1.7.0_40 or higher)
+ // first try Oracle's VM (we should also test for 1.7.0_40 or higher)
final String vendor = System.getProperty("java.vm.vendor");
boolean isOracle = vendor != null && vendor.toLowerCase().contains("Oracle".toLowerCase());
if (isOracle)
@@ -250,7 +250,7 @@ public class Viewer extends Frame implements WindowListener, ActionListener
return 1.0f;
}
- // try Apple VM
+ // try Apple VM
final Float scaleFactor = (Float)Toolkit.getDefaultToolkit().getDesktopProperty("apple.awt.contentScaleFactor");
if (scaleFactor != null && scaleFactor.intValue() == 2) {
return 2.0f;
diff --git a/platform/win32/libmupdf.vcproj b/platform/win32/libmupdf.vcproj
index 7ea08ee2..ec6778e2 100644
--- a/platform/win32/libmupdf.vcproj
+++ b/platform/win32/libmupdf.vcproj
@@ -1696,11 +1696,7 @@
RelativePath="..\..\source\pdf\pdf-repair.c"
>
</File>
- <File
- RelativePath="..\..\source\pdf\pdf-resources.c"
- >
- </File>
- <File
+ <File
RelativePath="..\..\source\pdf\pdf-resources.c"
>
</File>