Open Aitorbp opened 1 week ago
Changes to SearchView have been made on the following screens:
No changes will be made to the Users and group SearchView in the Share view.
Now, the searchbar includes a new resource with rounded edges, using the same background color (brandable) as the containing toolbar: rounded_search_view.xml
The new color #B4BAC0
of the hint text meets the contrast requirements of the issue:
The search cross will be in white color to meet the contrast requirements:
Research:
First of all, we need to know that there are two toolbars currently working in the application: RootToolbar
and StandardToolbar
.
The RootToolbar
is displayed in the following views:
Main list of files root view
Shares view
Spaces root view
Uploads view
Available offline view
The StandardToolbar
appears in the following views:
Main list of files (non-root) view
Spaces (non-root) view
Share with
)In this PR we are trying to unify the common appearance (colors, size...) of both toolbars in a single place. We are moving the general behaviour of the toolbar from the child classes to the ToolbarActivity
, avoiding repeated code. Regarding the StandardToolbar
, when we don't want the main_menu
(which includes Search
, Select all
and Share
buttons) to be displayed, we override the onCreateOptionsMenu
method to not showing it, which is the default behaviour provided in ToolbarActivity
.
This way, the following classes don't need to display the main_menu
so we override this method to return false
(won't be displayed):
UploadListActivity
( Uploads view
)ShareActivity
(Shares view
)PreviewImageActivity
( Image preview
)PreviewVideoActivity
(Video preview
)We need to do this now because these classes extend from ToolbarActivity
and main_menu
is attached to it.
On the other hand, we have fixed a bug. Now, when we are in the spaces view, the text hint of the SearchView is Search spaces
.
Related Issues
App:
ReleaseNotesViewModel.kt
creating a newReleaseNote()
with String resources (if required)QA