Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
A
abook_check
Overview
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
abook_android
abook_check
Commits
4e03e1bd
Commit
4e03e1bd
authored
Apr 24, 2020
by
Kim Jinsung
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
・新着更新中にログアウトするとアプリ強制される問題対応
・新着更新中にログアウトするとサーバ通信エラーメッセージ非表示
parent
52f75401
Show whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
28 additions
and
10 deletions
+28
-10
ABVJE_BL/src/jp/agentec/abook/abv/bl/download/ContentDownloader.java
+5
-3
ABVJE_UI_Android/src/jp/agentec/abook/abv/ui/common/activity/ABVAuthenticatedActivity.java
+12
-0
ABVJE_UI_Android/src/jp/agentec/abook/abv/ui/common/activity/ABVUIActivity.java
+4
-1
ABVJE_UI_Android/src/jp/agentec/abook/abv/ui/home/activity/ABookSettingActivity.java
+4
-0
ABVJE_UI_Android/src/jp/agentec/abook/abv/ui/home/activity/ABookSettingFragment.java
+3
-6
No files found.
ABVJE_BL/src/jp/agentec/abook/abv/bl/download/ContentDownloader.java
View file @
4e03e1bd
...
...
@@ -171,6 +171,8 @@ public class ContentDownloader {
Logger
.
e
(
TAG
,
"execKickTask encountered an exception."
,
e
);
}
catch
(
NetworkDisconnectedException
e
)
{
Logger
.
e
(
TAG
,
"execKickTask encountered an exception."
,
e
);
}
catch
(
Exception
e
)
{
Logger
.
e
(
TAG
,
"execKickTask encountered an exception."
,
e
);
}
finally
{
isKickTask
=
false
;
}
...
...
@@ -178,7 +180,7 @@ public class ContentDownloader {
});
}
private
void
execKickTask
()
throws
AcmsException
,
NetworkDisconnectedException
{
private
void
execKickTask
()
throws
AcmsException
,
NetworkDisconnectedException
,
Exception
{
autoPaused
=
false
;
if
(
Logger
.
isDebugEnabled
())
{
Logger
.
d
(
TAG
,
"downloaderMap %s"
,
getDownloadMapForDebug
());
...
...
@@ -622,7 +624,7 @@ public class ContentDownloader {
* @throws AcmsException
* @throws NetworkDisconnectedException
*/
private
void
startDownload
(
ContentDto
contentDto
)
throws
AcmsException
,
NetworkDisconnectedException
{
private
void
startDownload
(
ContentDto
contentDto
)
throws
AcmsException
,
NetworkDisconnectedException
,
Exception
{
contentDto
.
status
=
DownloadStatusType
.
Downloading
.
type
();
contentDto
.
resourcePath
=
ABVEnvironment
.
getInstance
().
getContentResourcesDirectoryPath
(
contentDto
.
contentId
,
false
);
contentDto
.
downloadStartDate
=
DateTimeUtil
.
getCurrentDate
();
...
...
@@ -691,7 +693,7 @@ public class ContentDownloader {
return
downloadUrl
;
}
private
GetContentParameters
getContentParameter
(
ContentDto
contentDto
)
{
private
GetContentParameters
getContentParameter
(
ContentDto
contentDto
)
throws
NullPointerException
{
GetContentParameters
param
;
param
=
new
GetContentParameters
(
contentDto
.
contentId
,
cache
.
getMemberInfo
().
sid
,
ContentZipType
.
ContentDownload
);
return
param
;
...
...
ABVJE_UI_Android/src/jp/agentec/abook/abv/ui/common/activity/ABVAuthenticatedActivity.java
View file @
4e03e1bd
...
...
@@ -500,9 +500,12 @@ public abstract class ABVAuthenticatedActivity extends ABVActivity implements Co
configureKeepScreen
();
}
if
(
e
!=
null
)
{
//新着更新時にログアウトすることで、SIDが取得できなく、例外が発生したときにはトースト非表示
if
(
ABVDataCache
.
getInstance
().
getMemberInfo
()
!=
null
)
{
handleError
(
e
);
}
}
}
});
}
...
...
@@ -737,6 +740,7 @@ public abstract class ABVAuthenticatedActivity extends ABVActivity implements Co
ErrorMessage
.
showErrorMessageToast
(
ABVAuthenticatedActivity
.
this
,
error
);
}
}
public
void
showUnAuthorizedContentWarningDialog
(
String
msg
)
{
ABookAlertDialog
alertDialog
=
AlertDialogUtil
.
createAlertDialog
(
this
,
getString
(
R
.
string
.
app_name
),
msg
);
alertDialog
.
setPositiveButton
(
R
.
string
.
ok
,
null
);
...
...
@@ -765,4 +769,12 @@ public abstract class ABVAuthenticatedActivity extends ABVActivity implements Co
public
boolean
isShowingBatchSync
()
{
return
batchSyncView
!=
null
&&
batchSyncView
.
isShowing
();
}
/**
* @version 1.2.300
* 新着情報更新処理を中止
*/
public
void
stopContentRefresher
()
{
contentRefresher
.
stopRefresh
();
}
}
ABVJE_UI_Android/src/jp/agentec/abook/abv/ui/common/activity/ABVUIActivity.java
View file @
4e03e1bd
...
...
@@ -442,10 +442,13 @@ public abstract class ABVUIActivity extends ABVAuthenticatedActivity {
}
});
}
//ログアウト時にも呼ばれるのでチェック
ABVDataCache
cache
=
ABVDataCache
.
getInstance
();
if
(
cache
.
getMemberInfo
()
!=
null
)
{
// 自動ダウンロード対象がある場合、新着更新が完了したあとに開始するように修正(jang)
ContentDownloader
.
getInstance
().
autoDownload
();
}
}
/**
* メモ・マーキング・しおりをコピーします
...
...
ABVJE_UI_Android/src/jp/agentec/abook/abv/ui/home/activity/ABookSettingActivity.java
View file @
4e03e1bd
...
...
@@ -83,4 +83,8 @@ public class ABookSettingActivity extends PreferenceActivity {
return
(
getResources
().
getConfiguration
().
screenLayout
&
Configuration
.
SCREENLAYOUT_SIZE_MASK
)
==
Configuration
.
SCREENLAYOUT_SIZE_NORMAL
;
}
public
void
stopContentRefresher
()
{
ABVUIActivity
activity
=
ActivityHandlingHelper
.
getInstance
().
getPreviousOfSettingActivity
();
activity
.
stopContentRefresher
();
}
}
ABVJE_UI_Android/src/jp/agentec/abook/abv/ui/home/activity/ABookSettingFragment.java
View file @
4e03e1bd
...
...
@@ -35,7 +35,6 @@ import jp.agentec.abook.abv.bl.acms.type.AcmsApis;
import
jp.agentec.abook.abv.bl.common.ABVEnvironment
;
import
jp.agentec.abook.abv.bl.common.CommonExecutor
;
import
jp.agentec.abook.abv.bl.common.Constant
;
import
jp.agentec.abook.abv.bl.common.constant.ABookKeys
;
import
jp.agentec.abook.abv.bl.common.log.Logger
;
import
jp.agentec.abook.abv.bl.data.ABVDataCache
;
import
jp.agentec.abook.abv.bl.dto.MemberInfoDto
;
...
...
@@ -49,19 +48,14 @@ import jp.agentec.abook.abv.launcher.android.OnAppDownloadReceiver;
import
jp.agentec.abook.abv.launcher.android.R
;
import
jp.agentec.abook.abv.ui.common.appinfo.AppDefType
;
import
jp.agentec.abook.abv.ui.common.appinfo.AppDefType.UserPrefKey
;
import
jp.agentec.abook.abv.ui.common.appinfo.options.Options
;
import
jp.agentec.abook.abv.ui.common.dialog.ABookAlertDialog
;
import
jp.agentec.abook.abv.ui.common.helper.ProgressDialogHelper
;
import
jp.agentec.abook.abv.ui.common.util.ABVToastUtil
;
import
jp.agentec.abook.abv.ui.common.util.AlertDialogUtil
;
import
jp.agentec.abook.abv.ui.common.util.PatternStringUtil
;
import
jp.agentec.abook.abv.ui.home.helper.ABookPermissionHelper
;
import
jp.agentec.adf.util.DateTimeFormat
;
import
jp.agentec.adf.util.DateTimeUtil
;
import
static
jp
.
agentec
.
abook
.
abv
.
cl
.
util
.
PreferenceUtil
.
getUserPref
;
import
static
jp
.
agentec
.
abook
.
abv
.
cl
.
util
.
PreferenceUtil
.
putUserPref
;
public
class
ABookSettingFragment
extends
PreferenceFragment
{
private
static
final
String
TAG
=
"ABookSettingActivity"
;
...
...
@@ -191,6 +185,9 @@ public class ABookSettingFragment extends PreferenceFragment {
ABVToastUtil
.
showMakeText
(
getActivity
(),
R
.
string
.
ERROR
,
Toast
.
LENGTH_SHORT
);
}
// 新着更新が実行されている場合停止
((
ABookSettingActivity
)
getActivity
()).
stopContentRefresher
();
SharedPreferences
sharedPreferences
=
getActivity
().
getSharedPreferences
(
AppDefType
.
PrefName
.
USER_PREFERENCE
,
Context
.
MODE_PRIVATE
);
sharedPreferences
.
edit
().
remove
(
AppDefType
.
UserPrefKey
.
GUEST_LOGIN
).
commit
();
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment