Commit e766b592 by Kim Jinsung

Merge branch 'contract/sato/1.0.1_34545' into 'contract/sato/1.0.1'

Contract/sato/1.0.1 34545

See merge request !27
parents cf4233a0 8bd35390
......@@ -44,7 +44,6 @@
android:icon="@drawable/app_icon"
android:label="@string/app_name"
android:theme="@style/ABook"
android:allowBackup="false"
android:largeHeap="true" >
<!-- LinkingビーコンIFの使用宣言 -->
......
......@@ -92,18 +92,27 @@ android {
abiFilters "armeabi-v7a", ""
}
}
x86 {
armv8 {
versionCode defaultConfig.versionCode + 1
ndk {
abiFilters "arm64-v8a", ""
}
}
x86 {
versionCode defaultConfig.versionCode + 2
ndk {
abiFilters "x86", ""
}
}
// 容量が大きいため、コメントアウト
// x86_armv7 {
// ndk {
// abiFilters "x86", "armeabi-v7a", ""
// }
// }
x86_64 {
versionCode defaultConfig.versionCode + 3
ndk {
abiFilters "x86_64", ""
}
}
} else {
armv7 {
versionCode defaultConfig.versionCode
......@@ -111,6 +120,13 @@ android {
abiFilters "armeabi-v7a", ""
}
}
armv8 {
versionCode defaultConfig.versionCode + 1
ndk {
abiFilters "arm64-v8a", ""
}
}
}
}
}
......
......@@ -11,7 +11,7 @@ android {
defaultConfig {
minSdkVersion 18
targetSdkVersion 26
targetSdkVersion 28
//abvEnvironments
resValue("string", "acms_address", "${acms_address}")
resValue("string", "download_server_address", "${download_server_address}")
......
......@@ -19,7 +19,7 @@ dependencies {
implementation 'com.google.zxing:core:3.2.1'
implementation 'org.jsoup:jsoup:1.9.2'
implementation project(':xwalk_core_library')
implementation files('libs/FoxitRDK.jar')
implementation project(':FoxitRDK')
implementation project(':SwiftDecoderMobile')
implementation files('libs/sdaiflib.jar')
}
......@@ -30,7 +30,7 @@ android {
defaultConfig {
minSdkVersion 18
targetSdkVersion 26
targetSdkVersion 28
multiDexEnabled true
}
sourceSets {
......
......@@ -2,6 +2,7 @@ package jp.agentec.abook.abv.cl.util;
import jp.agentec.abook.abv.bl.acms.client.json.content.MediaInfoJSON;
import jp.agentec.abook.abv.bl.acms.client.json.content.PageObjectJSON;
import jp.agentec.abook.abv.bl.common.Constant;
import jp.agentec.abook.abv.bl.common.log.Logger;
import jp.agentec.abook.abv.bl.data.dao.AbstractDao;
import jp.agentec.abook.abv.bl.data.dao.ContentObjectLogDao;
......@@ -13,6 +14,7 @@ import jp.agentec.abook.abv.bl.logic.ContentReadingLogLogic;
import jp.agentec.abook.abv.bl.logic.ContractLogic;
import jp.agentec.abook.abv.bl.websocket.MeetingManager;
import jp.agentec.abook.abv.launcher.android.R;
import jp.agentec.abook.abv.ui.home.helper.ABookPermissionHelper;
import jp.agentec.adf.util.DateTimeUtil;
import org.json.adf.JSONException;
......@@ -51,7 +53,8 @@ public class ContentLogUtil {
int readingLogId = contentReadingLogLogic.startContentReadLog(contentId);
// 位置情報取得許可、サービスオプション、ビルドオプションチェック
if (checkUsableReadinglogGps(contentId)) { //20190529 アプリ側の位置情報許可チェックはしない
ABookPermissionHelper helper = new ABookPermissionHelper(context, Constant.ABookPermissionType.AccessFineLocation, null);
if (helper.checkMultiPermissions(false) && checkUsableReadinglogGps(contentId)) { //20190529 アプリ側の位置情報許可チェックはしない
// 位置情報取得
locationManagerUtil = new LocationManagerUtil(context, new LocationManagerUtil.LocationManagerUtilListener() {
@Override
......
......@@ -2,6 +2,7 @@ package jp.agentec.abook.abv.ui.home.activity;
import android.app.Activity;
import android.content.Intent;
import android.os.Build;
import android.os.Bundle;
import jp.agentec.abook.abv.launcher.android.R;
......@@ -14,8 +15,11 @@ public class PreSplashActivity extends Activity {
static {
try {
System.loadLibrary("skia_android");
System.loadLibrary("ozrv");
// アーキテクチャがx86以外の場合のみ、以下のライブラリをロードする。
if (!Build.CPU_ABI.contains("x86")) {
System.loadLibrary("skia_android");
System.loadLibrary("ozrv");
}
} catch (Exception e) {
e.printStackTrace();
}
......
......@@ -3,6 +3,7 @@ package jp.agentec.abook.abv.ui.home.helper;
import android.Manifest;
import android.app.Activity;
import android.app.AlertDialog;
import android.content.Context;
import android.content.DialogInterface;
import android.content.Intent;
import android.content.pm.PackageManager;
......@@ -32,19 +33,19 @@ import static jp.agentec.abook.abv.cl.util.PreferenceUtil.getUserPref;
* Created by kim jinsung on 2018/09/21.
*/
public class ABookPermissionHelper {
private Activity mActivity;
private Context mContext;
private int mPermitionType;
private AlertDialog mAlertDialog;
private Callback mCallback;
public ABookPermissionHelper(Activity activity, int permissionType, Callback callback) {
mActivity = activity;
public ABookPermissionHelper(Context context, int permissionType, Callback callback) {
mContext = context;
mPermitionType = permissionType;
mCallback = callback;
}
public ABookPermissionHelper(Activity activity) {
mActivity = activity;
public ABookPermissionHelper(Context context) {
mContext = context;
}
public ArrayList<String> checkMultiPermissions() {
......@@ -55,35 +56,35 @@ public class ABookPermissionHelper {
return reqPermissions;
}
// 位置情報
if (ContextCompat.checkSelfPermission(mActivity,
if (ContextCompat.checkSelfPermission(mContext,
android.Manifest.permission.ACCESS_FINE_LOCATION) != PackageManager.PERMISSION_GRANTED) {
reqPermissions.add(android.Manifest.permission.ACCESS_FINE_LOCATION);
}
if (ContextCompat.checkSelfPermission(mActivity,
if (ContextCompat.checkSelfPermission(mContext,
android.Manifest.permission.ACCESS_COARSE_LOCATION) != PackageManager.PERMISSION_GRANTED) {
reqPermissions.add(android.Manifest.permission.ACCESS_COARSE_LOCATION);
}
// ストレージ
if (ContextCompat.checkSelfPermission(mActivity,
if (ContextCompat.checkSelfPermission(mContext,
android.Manifest.permission.READ_EXTERNAL_STORAGE) != PackageManager.PERMISSION_GRANTED) {
reqPermissions.add(android.Manifest.permission.READ_EXTERNAL_STORAGE);
}
if (ContextCompat.checkSelfPermission(mActivity,
if (ContextCompat.checkSelfPermission(mContext,
android.Manifest.permission.WRITE_EXTERNAL_STORAGE) != PackageManager.PERMISSION_GRANTED) {
reqPermissions.add(android.Manifest.permission.WRITE_EXTERNAL_STORAGE);
}
// カメラ
if (ContextCompat.checkSelfPermission(mActivity,
if (ContextCompat.checkSelfPermission(mContext,
android.Manifest.permission.CAMERA) != PackageManager.PERMISSION_GRANTED) {
reqPermissions.add(android.Manifest.permission.CAMERA);
}
// マイク(オーディオ)
if (ContextCompat.checkSelfPermission(mActivity,
if (ContextCompat.checkSelfPermission(mContext,
android.Manifest.permission.RECORD_AUDIO) != PackageManager.PERMISSION_GRANTED) {
reqPermissions.add(android.Manifest.permission.RECORD_AUDIO);
}
// Bluetooth
if (ContextCompat.checkSelfPermission(mActivity,
if (ContextCompat.checkSelfPermission(mContext,
android.Manifest.permission.BLUETOOTH) != PackageManager.PERMISSION_GRANTED) {
reqPermissions.add(android.Manifest.permission.BLUETOOTH);
}
......@@ -100,77 +101,77 @@ public class ABookPermissionHelper {
switch (mPermitionType) {
case Constant.ABookPermissionType.ReadExternalStorage:
// ストレージ
if (ContextCompat.checkSelfPermission(mActivity, android.Manifest.permission.READ_EXTERNAL_STORAGE) != PERMISSION_GRANTED ||
ContextCompat.checkSelfPermission(mActivity, android.Manifest.permission.WRITE_EXTERNAL_STORAGE) != PERMISSION_GRANTED) {
if (mActivity instanceof HTMLWebViewActivity || mActivity instanceof HTMLXWalkWebViewActivity || mActivity instanceof OperationListActivity) {
if (ContextCompat.checkSelfPermission(mContext, android.Manifest.permission.READ_EXTERNAL_STORAGE) != PERMISSION_GRANTED ||
ContextCompat.checkSelfPermission(mContext, android.Manifest.permission.WRITE_EXTERNAL_STORAGE) != PERMISSION_GRANTED) {
if (mContext instanceof HTMLWebViewActivity || mContext instanceof HTMLXWalkWebViewActivity || mContext instanceof OperationListActivity) {
// リソースパターンの適用
permitionTextResourceId = PatternStringUtil.patternToInt(mActivity.getApplicationContext(),
permitionTextResourceId = PatternStringUtil.patternToInt(mContext,
R.string.msg_permission_dialog_storage_album,
getUserPref(mActivity.getApplicationContext(), AppDefType.UserPrefKey.RESOURCE_PATTERN_TYPE, 0));
getUserPref(mContext, AppDefType.UserPrefKey.RESOURCE_PATTERN_TYPE, 0));
} else {
// リソースパターンの適用
permitionTextResourceId = PatternStringUtil.patternToInt(mActivity.getApplicationContext(),
permitionTextResourceId = PatternStringUtil.patternToInt(mContext,
R.string.msg_permission_dialog_storage_update,
getUserPref(mActivity.getApplicationContext(), AppDefType.UserPrefKey.RESOURCE_PATTERN_TYPE, 0));
getUserPref(mContext, AppDefType.UserPrefKey.RESOURCE_PATTERN_TYPE, 0));
}
}
break;
case Constant.ABookPermissionType.AccessFineLocation:
// 位置情報
if (ContextCompat.checkSelfPermission(mActivity,
if (ContextCompat.checkSelfPermission(mContext,
android.Manifest.permission.ACCESS_FINE_LOCATION) != PERMISSION_GRANTED) {
// リソースパターンの適用
permitionTextResourceId = PatternStringUtil.patternToInt(mActivity.getApplicationContext(),
permitionTextResourceId = PatternStringUtil.patternToInt(mContext,
R.string.msg_permission_dialog_location,
getUserPref(mActivity.getApplicationContext(), AppDefType.UserPrefKey.RESOURCE_PATTERN_TYPE, 0));
getUserPref(mContext, AppDefType.UserPrefKey.RESOURCE_PATTERN_TYPE, 0));
}
if (ContextCompat.checkSelfPermission(mActivity,
if (ContextCompat.checkSelfPermission(mContext,
android.Manifest.permission.ACCESS_COARSE_LOCATION) != PERMISSION_GRANTED) {
// リソースパターンの適用
permitionTextResourceId = PatternStringUtil.patternToInt(mActivity.getApplicationContext(),
permitionTextResourceId = PatternStringUtil.patternToInt(mContext,
R.string.msg_permission_dialog_location,
getUserPref(mActivity.getApplicationContext(), AppDefType.UserPrefKey.RESOURCE_PATTERN_TYPE, 0));
getUserPref(mContext, AppDefType.UserPrefKey.RESOURCE_PATTERN_TYPE, 0));
}
break;
case Constant.ABookPermissionType.Camera:
// カメラ
if (ContextCompat.checkSelfPermission(mActivity,
if (ContextCompat.checkSelfPermission(mContext,
android.Manifest.permission.CAMERA) != PERMISSION_GRANTED) {
// リソースパターンの適用
permitionTextResourceId = PatternStringUtil.patternToInt(mActivity.getApplicationContext(),
permitionTextResourceId = PatternStringUtil.patternToInt(mContext,
R.string.msg_permission_dialog_camera,
getUserPref(mActivity.getApplicationContext(), AppDefType.UserPrefKey.RESOURCE_PATTERN_TYPE, 0));
getUserPref(mContext, AppDefType.UserPrefKey.RESOURCE_PATTERN_TYPE, 0));
}
break;
case Constant.ABookPermissionType.Audio:
// マイク(オーディオ)
if (ContextCompat.checkSelfPermission(mActivity,
if (ContextCompat.checkSelfPermission(mContext,
android.Manifest.permission.RECORD_AUDIO) != PERMISSION_GRANTED) {
// リソースパターンの適用
permitionTextResourceId = PatternStringUtil.patternToInt(mActivity.getApplicationContext(),
permitionTextResourceId = PatternStringUtil.patternToInt(mContext,
R.string.msg_permission_dialog_mic,
getUserPref(mActivity.getApplicationContext(), AppDefType.UserPrefKey.RESOURCE_PATTERN_TYPE, 0));
getUserPref(mContext, AppDefType.UserPrefKey.RESOURCE_PATTERN_TYPE, 0));
}
break;
}
if (permitionTextResourceId > 0) {
if (showDialogFlg) {
ABookAlertDialog dialog = AlertDialogUtil.createABookAlertDialog(mActivity);
ABookAlertDialog dialog = AlertDialogUtil.createABookAlertDialog(mContext);
// リソースパターンの適用
dialog.setTitle(PatternStringUtil.patternToString(mActivity.getApplicationContext(),
dialog.setTitle(PatternStringUtil.patternToString(mContext,
R.string.title_permission_dialog,
getUserPref(mActivity.getApplicationContext(), AppDefType.UserPrefKey.RESOURCE_PATTERN_TYPE, 0)));
getUserPref(mContext, AppDefType.UserPrefKey.RESOURCE_PATTERN_TYPE, 0)));
dialog.setMessage(permitionTextResourceId);
dialog.setPositiveButton(R.string.ok, new DialogInterface.OnClickListener() {
@Override
public void onClick(DialogInterface dialog, int which) {
Intent intent = new Intent(Settings.ACTION_APPLICATION_DETAILS_SETTINGS);
Uri uri = Uri.fromParts("package", mActivity.getPackageName(), null);
Uri uri = Uri.fromParts("package", mContext.getPackageName(), null);
intent.setData(uri);
mActivity.startActivity(intent);
mContext.startActivity(intent);
if (mCallback != null) {
mCallback.callback(true);
}
......
......@@ -259,9 +259,22 @@ public class CheckOZDViewActivity extends ABVContentViewActivity {
strParam += "viewer.exportcommand=true#";
strParam += "toolbar.etc=false#";
strParam += "eform.inputeventcommand=true#";
strParam += "eform.imagepicker_camera_show_choose_button=true#";
return strParam;
}
@Override
protected void onActivityResult(int requestCode, int resultCode, Intent data) {
if(mOzReportViewer != null) {
//requestCode: 呼び出されたActivityに対する識別コード
//resultCode: ユーザーの操作の結果コード
//data: ギャラリーで選択したイメージ情報のIntent
mOzReportViewer.onActivityResult(this, requestCode, resultCode, data);
}
}
private boolean openViewer(String param) {
if (!(mIsSkiaLoad && mIsViewerLoad)) {
if (!loadLibrary()) {
......
......@@ -103,7 +103,9 @@ public class HTMLWebViewActivity extends ParentWebViewActivity {
webView = (WebView) findViewById(R.id.webView2);
webView.setVisibility(View.VISIBLE);
webView.setVerticalScrollbarOverlay(true); // スクロールバー部分の隙間を消す
webView.setWebContentsDebuggingEnabled(true); //デバッグモード(chromeからinspect可)
if (Logger.isDebugEnabled()) {
webView.setWebContentsDebuggingEnabled(true); //デバッグモード(chromeからinspect可)
}
// webView.setWebViewClient(new WebViewClient());
// //ブラウザの描画領域を対象としたイベントをフック
WebSettings settings = webView.getSettings();
......
......@@ -119,9 +119,9 @@ public class HTMLXWalkWebViewActivity extends ParentWebViewActivity {
settings.setUseWideViewPort(true); // 画面の横幅にページの横幅を合わせる
settings.setDomStorageEnabled(true); // WebStorage有効化
settings.setCacheMode(XWalkSettings.LOAD_NO_CACHE);
XWalkPreferences.setValue(XWalkPreferences.REMOTE_DEBUGGING, true); //デバッグモード(chromeからinspect可)
if (Logger.isDebugEnabled()) {
XWalkPreferences.setValue(XWalkPreferences.REMOTE_DEBUGGING, true); //デバッグモード(chromeからinspect可)
}
final RelativeLayout fl = (RelativeLayout) findViewById(R.id.frameTopbar);
// ***** 戻るボタン
......
......@@ -35,7 +35,7 @@ public class ActionZoomLayout extends RelativeLayout {
@Override
protected void dispatchDraw(Canvas canvas) {
canvas.save(Canvas.MATRIX_SAVE_FLAG);
canvas.save(Canvas.ALL_SAVE_FLAG);
canvas.concat(imgMatrix);
super.dispatchDraw(canvas);
canvas.restore();
......
......@@ -14,7 +14,7 @@ public class EnqueteWebView extends WebView {
@Override
protected void onDraw(android.graphics.Canvas canvas) {
canvas.saveLayerAlpha(0, 0, Float.MAX_VALUE, Float.MAX_VALUE, alpha, Canvas.HAS_ALPHA_LAYER_SAVE_FLAG);
canvas.saveLayerAlpha(0, 0, Float.MAX_VALUE, Float.MAX_VALUE, alpha, Canvas.ALL_SAVE_FLAG);
super.onDraw(canvas);
}
......
......@@ -179,7 +179,7 @@ public class ZoomRelativeLayout extends RelativeLayout {
@Override
protected void dispatchDraw(Canvas canvas) {
canvas.save(Canvas.MATRIX_SAVE_FLAG);
canvas.save(Canvas.ALL_SAVE_FLAG);
if (!isOperationPdf) {
canvas.concat(imgMatrix);
}
......
configurations.maybeCreate("default")
artifacts.add("default", file('FoxitRDK.aar'))
\ No newline at end of file
include ':ABVJE_BL', ':ABVJE_Launcher_Android', ':ABVJE_Res_Default_Android', ':ABVJE_UI_Android', ':SwiftDecoderMobile'
include ':xwalk_core_library'
include ':FoxitRDK'
\ No newline at end of file
......@@ -6,7 +6,7 @@ android {
defaultConfig {
minSdkVersion 16
targetSdkVersion 26
targetSdkVersion 28
}
buildTypes {
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment