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
0760f0fc
Commit
0760f0fc
authored
Sep 09, 2021
by
onuma
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
タスクが残らないように修正。
parent
3ceba6c7
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
41 additions
and
23 deletions
+41
-23
ABVJE_Launcher_Android/AndroidManifest.xml
+3
-1
ABVJE_UI_Android/src/jp/agentec/abook/abv/ui/home/activity/ChatWebViewActivity.java
+37
-21
ABVJE_UI_Android/src/jp/agentec/abook/abv/ui/home/helper/ActivityHandlingHelper.java
+1
-1
No files found.
ABVJE_Launcher_Android/AndroidManifest.xml
View file @
0760f0fc
...
...
@@ -251,9 +251,11 @@
android:theme=
"@style/Theme.AppCompat.Light.NoActionBar.FullScreen"
>
</activity>
<activity
android:name=
"jp.agentec.abook.abv.ui.home.activity.ChatWebViewActivity"
android:configChanges=
"screenSize|smallestScreenSize|screenLayout|orientation"
<activity
android:name=
"jp.agentec.abook.abv.ui.home.activity.ChatWebViewActivity"
android:configChanges=
"screenSize|smallestScreenSize|screenLayout|orientation"
android:taskAffinity=
".ChatWebViewActivity"
android:resizeableActivity=
"true"
android:excludeFromRecents=
"true"
android:supportsPictureInPicture=
"true"
/>
</application>
...
...
ABVJE_UI_Android/src/jp/agentec/abook/abv/ui/home/activity/ChatWebViewActivity.java
View file @
0760f0fc
...
...
@@ -112,6 +112,8 @@ public class ChatWebViewActivity extends CommunicationWebViewActivity implements
private
String
selectedUserIdList
;
private
String
mSkey
;
private
boolean
isPIP
;
private
boolean
startPIP
=
false
;
// PIPモードを開始していたらtrue;
private
boolean
needFinishOnStop
=
false
;
// ×ボタンでPIP閉じた時用
private
boolean
isStop
;
private
String
encodedFilePath
;
...
...
@@ -794,7 +796,7 @@ public class ChatWebViewActivity extends CommunicationWebViewActivity implements
}
else
{
intent
.
setClass
(
ChatWebViewActivity
.
this
,
OperationListActivity
.
class
);
}
intent
.
setFlags
(
Intent
.
FLAG_ACTIVITY_SINGLE_TOP
|
Intent
.
FLAG_ACTIVITY_CLEAR_T
ASK
);
intent
.
setFlags
(
Intent
.
FLAG_ACTIVITY_SINGLE_TOP
|
Intent
.
FLAG_ACTIVITY_CLEAR_T
OP
);
intent
.
putExtra
(
AppDefType
.
ChatPushMessageKey
.
baseActivityName
,
ChatWebViewActivity
.
class
.
getName
());
startActivity
(
intent
,
NaviConsts
.
Left
);
}
...
...
@@ -806,17 +808,20 @@ public class ChatWebViewActivity extends CommunicationWebViewActivity implements
}
}
/**
* PIPモードから元にもどる
*/
public
void
finishPIPmode
()
{
if
(!
isPIP
)
{
return
;
}
getApplication
()
.
startActivity
(
new
Intent
(
this
,
ChatWebViewActivity
.
class
)
.
addFlags
(
Intent
.
FLAG_ACTIVITY_REORDER_TO_FRONT
|
Intent
.
FLAG_ACTIVITY_NEW_TASK
)
);
}
public
void
startPIPmode
()
{
PictureInPictureParams
.
Builder
mPipBuilder
=
new
PictureInPictureParams
.
Builder
()
;
enterPictureInPictureMode
(
mPipBuilder
.
build
());
if
(!
isPIP
)
{
return
;
}
if
(
startPIP
)
{
Intent
intent
=
new
Intent
(
);
intent
.
setClass
(
this
,
ChatWebViewActivity
.
class
);
intent
.
setFlags
(
Intent
.
FLAG_ACTIVITY_REORDER_TO_FRONT
);
getApplication
().
startActivity
(
intent
);
startPIP
=
false
;
}
}
public
void
exitAndDeleteMeetingRoom
()
{
...
...
@@ -842,8 +847,6 @@ public class ChatWebViewActivity extends CommunicationWebViewActivity implements
Intent
intent
=
new
Intent
();
intent
.
setClass
(
targetActivity
,
OperationRelatedContentActivity
.
class
);
intent
.
setFlags
(
Intent
.
FLAG_ACTIVITY_SINGLE_TOP
|
Intent
.
FLAG_ACTIVITY_EXCLUDE_FROM_RECENTS
);
intent
.
putExtra
(
"isCollaboration"
,
true
);
intent
.
putExtra
(
"isCollaborationOwner"
,
isOwner
);
targetActivity
.
startActivity
(
intent
);
}
public
void
connectMeetingServer
()
throws
Exception
{
...
...
@@ -1013,6 +1016,19 @@ public class ChatWebViewActivity extends CommunicationWebViewActivity implements
protected
void
onStop
()
{
isStop
=
true
;
super
.
onStop
();
if
(
needFinishOnStop
)
{
try
{
chatData
.
finishCollaboration
();
}
catch
(
NetworkDisconnectedException
e
)
{
e
.
printStackTrace
();
}
catch
(
AcmsException
e
)
{
e
.
printStackTrace
();
}
// PIPモードは、状態変化のイベントがonStopくらいしかない。なので、PIPの時は、ここでfinish()する
finish
();
needFinishOnStop
=
false
;
}
}
@Override
...
...
@@ -1248,8 +1264,7 @@ public class ChatWebViewActivity extends CommunicationWebViewActivity implements
public
int
createContentView
()
{
finishBeforeContentListActivity
();
PictureInPictureParams
.
Builder
mPipBuilder
=
new
PictureInPictureParams
.
Builder
();
enterPictureInPictureMode
(
mPipBuilder
.
build
());
startPIPMode
();
Integer
meetingId
=
null
;
meetingManager
.
close
();
try
{
...
...
@@ -1272,8 +1287,7 @@ public class ChatWebViewActivity extends CommunicationWebViewActivity implements
public
void
startContentView
()
{
finishBeforeContentListActivity
();
PictureInPictureParams
.
Builder
mPipBuilder
=
new
PictureInPictureParams
.
Builder
();
enterPictureInPictureMode
(
mPipBuilder
.
build
());
startPIPMode
();
meetingManager
.
close
();
try
{
connectMeetingServer
();
...
...
@@ -1288,8 +1302,7 @@ public class ChatWebViewActivity extends CommunicationWebViewActivity implements
public
void
joinMeetingRoom
(
int
newMeetingId
)
{
finishBeforeContentListActivity
();
PictureInPictureParams
.
Builder
mPipBuilder
=
new
PictureInPictureParams
.
Builder
();
enterPictureInPictureMode
(
mPipBuilder
.
build
());
startPIPMode
();
meetingManager
.
close
();
try
{
connectMeetingServer
();
...
...
@@ -1301,10 +1314,14 @@ public class ChatWebViewActivity extends CommunicationWebViewActivity implements
}
startContentListActivity
(
false
);
}
/**
* PIPモードに変更
*/
public
void
startPIPMode
()
{
PictureInPictureParams
.
Builder
mPipBuilder
=
new
PictureInPictureParams
.
Builder
();
enterPictureInPictureMode
(
mPipBuilder
.
build
());
needFinishOnStop
=
true
;
startPIP
=
true
;
}
public
void
exitPIPmode
()
{
...
...
@@ -1348,5 +1365,4 @@ public class ChatWebViewActivity extends CommunicationWebViewActivity implements
// 最後のチャットのルーム
PreferenceUtil
.
putUserPref
(
getApplicationContext
(),
AppDefType
.
UserPrefKey
.
CHAT_LAST_ROOMID
,
roomId
);
}
}
ABVJE_UI_Android/src/jp/agentec/abook/abv/ui/home/helper/ActivityHandlingHelper.java
View file @
0760f0fc
...
...
@@ -388,7 +388,7 @@ public class ActivityHandlingHelper extends ABookHelper implements RemoteObserve
//資料が変更されたらPIPモードに更新する。
ChatWebViewActivity
chatWebViewActivity
=
getActivity
(
ChatWebViewActivity
.
class
);
if
(
chatWebViewActivity
!=
null
&&
meetingManager
.
isSubscribed
()
&&
!
chatWebViewActivity
.
isInPictureInPictureMode
())
{
chatWebViewActivity
.
startPIP
m
ode
();
chatWebViewActivity
.
startPIP
M
ode
();
}
if
(!
StringUtil
.
equalsAny
(
...
...
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