Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Room Park Android
Project
Project
Details
Activity
Releases
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
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Vladislav Bogdashkin
Room Park Android
Commits
bfc2a9e6
Commit
bfc2a9e6
authored
Mar 12, 2020
by
Vladislav Bogdashkin
🎣
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
screen orientation for photo viewer
parent
9f75c250
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
4 additions
and
0 deletions
+4
-0
PhotoDialogController.kt
...conductor/dialogs/change_handler/PhotoDialogController.kt
+4
-0
No files found.
app/src/main/java/com/biganto/visual/roompark/conductor/dialogs/change_handler/PhotoDialogController.kt
View file @
bfc2a9e6
package
com.biganto.visual.roompark.conductor.dialogs.change_handler
import
android.content.pm.ActivityInfo
import
android.os.Bundle
import
android.view.LayoutInflater
import
android.view.View
...
...
@@ -32,6 +33,8 @@ class PhotoDialogController : Controller {
override
fun
onCreateView
(
inflater
:
LayoutInflater
,
container
:
ViewGroup
):
View
{
val
view
=
inflater
.
inflate
(
getLayoutId
(),
container
,
false
)
activity
?.
requestedOrientation
=
ActivityInfo
.
SCREEN_ORIENTATION_USER_LANDSCAPE
args
.
getString
(
PHOTO_URL_KEY
)
?.
let
{
val
photoView
=
view
.
findViewById
<
PhotoView
>(
R
.
id
.
photo_frame
)
Glide
.
with
(
photoView
)
...
...
@@ -50,6 +53,7 @@ class PhotoDialogController : Controller {
fun
getLayoutId
()
=
R
.
layout
.
photo_viewer
override
fun
handleBack
():
Boolean
{
activity
?.
requestedOrientation
=
ActivityInfo
.
SCREEN_ORIENTATION_USER_PORTRAIT
return
router
.
popCurrentController
()
}
...
...
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