Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
LatinIME
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Deploy
Releases
Package Registry
Container Registry
Model registry
Operate
Terraform modules
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
keyboard
LatinIME
Commits
ea6cb4d0
Commit
ea6cb4d0
authored
5 months ago
by
Aleksandras Kostarevas
Browse files
Options
Downloads
Patches
Plain Diff
Maintain consistent height when action is triggered with action bar open
parent
7b5d6b73
No related branches found
Branches containing commit
No related tags found
Tags containing commit
No related merge requests found
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
java/src/org/futo/inputmethod/latin/uix/ActionBar.kt
+9
-9
9 additions, 9 deletions
java/src/org/futo/inputmethod/latin/uix/ActionBar.kt
java/src/org/futo/inputmethod/latin/uix/UixManager.kt
+2
-1
2 additions, 1 deletion
java/src/org/futo/inputmethod/latin/uix/UixManager.kt
with
11 additions
and
10 deletions
java/src/org/futo/inputmethod/latin/uix/ActionBar.kt
+
9
−
9
View file @
ea6cb4d0
...
...
@@ -131,6 +131,8 @@ import kotlin.math.roundToInt
* TODO: Will need to make RTL languages work
*/
val
ActionBarHeight
=
40
.
dp
val
ActionBarScrollIndexSetting
=
SettingsKey
(
intPreferencesKey
(
"action_bar_scroll_index"
),
0
...
...
@@ -703,18 +705,16 @@ fun ActionBar(
val
view
=
LocalView
.
current
val
context
=
LocalContext
.
current
val
actionBarHeight
=
40
.
dp
val
oldActionBar
=
useDataStore
(
OldStyleActionsBar
)
Column
{
Column
(
Modifier
.
height
(
ActionBarHeight
*
if
(
isActionsExpanded
)
2
else
1
))
{
if
(
isActionsExpanded
&&
!
oldActionBar
.
value
)
{
ActionSep
()
Surface
(
modifier
=
Modifier
.
fillMaxWidth
()
.
h
eight
(
actionBarHeight
),
color
=
MaterialTheme
.
colorScheme
.
background
.
w
eight
(
1.0f
),
color
=
MaterialTheme
.
colorScheme
.
background
)
{
ActionItems
(
onActionActivated
,
onActionAltActivated
)
}
...
...
@@ -725,7 +725,7 @@ fun ActionBar(
Surface
(
modifier
=
Modifier
.
fillMaxWidth
()
.
h
eight
(
actionBarHeight
),
color
=
MaterialTheme
.
colorScheme
.
background
.
w
eight
(
1.0f
),
color
=
MaterialTheme
.
colorScheme
.
background
)
{
Row
{
ExpandActionsButton
(
isActionsExpanded
)
{
...
...
@@ -793,12 +793,12 @@ fun ActionWindowBar(
onBack
:
()
->
Unit
,
onExpand
:
()
->
Unit
)
{
Column
{
Column
(
Modifier
.
height
(
ActionBarHeight
))
{
ActionSep
()
Surface
(
modifier
=
Modifier
.
fillMaxWidth
()
.
h
eight
(
40
.
dp
),
color
=
MaterialTheme
.
colorScheme
.
background
.
w
eight
(
1.0f
),
color
=
MaterialTheme
.
colorScheme
.
background
)
{
Row
{
...
...
@@ -833,12 +833,12 @@ fun CollapsibleSuggestionsBar(
words
:
SuggestedWords
?,
suggestionStripListener
:
SuggestionStripViewListener
,
)
{
Column
{
Column
(
Modifier
.
height
(
ActionBarHeight
))
{
ActionSep
()
Surface
(
modifier
=
Modifier
.
fillMaxWidth
()
.
h
eight
(
40
.
dp
),
color
=
MaterialTheme
.
colorScheme
.
background
.
w
eight
(
1.0f
),
color
=
MaterialTheme
.
colorScheme
.
background
)
{
Row
{
...
...
This diff is collapsed.
Click to expand it.
java/src/org/futo/inputmethod/latin/uix/UixManager.kt
+
2
−
1
View file @
ea6cb4d0
...
...
@@ -542,7 +542,8 @@ class UixManager(private val latinIME: LatinIME) {
.
height
(
with
(
LocalDensity
.
current
)
{
(
latinIME
.
getInputViewHeight
()
.
toFloat
()
/
heightDiv
.
toFloat
()).
toDp
()
.
toFloat
()
/
heightDiv
.
toFloat
()).
toDp
()
+
if
(
actionsExpanded
)
ActionBarHeight
else
0
.
dp
})
)
{
windowImpl
.
WindowContents
(
keyboardShown
=
!
isMainKeyboardHidden
)
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment