Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
A
AloqaIM-Android
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Boards
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
Administrator
AloqaIM-Android
Commits
db7f265f
Commit
db7f265f
authored
Sep 04, 2017
by
Filipe de Lima Brito
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Update MainActivity.java
parent
693dea77
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
0 additions
and
52 deletions
+0
-52
MainActivity.java
.../main/java/chat/rocket/android/activity/MainActivity.java
+0
-52
No files found.
app/src/main/java/chat/rocket/android/activity/MainActivity.java
View file @
db7f265f
...
...
@@ -4,7 +4,6 @@ import android.os.Bundle;
import
android.support.annotation.Nullable
;
import
android.support.design.widget.Snackbar
;
import
android.support.v4.widget.SlidingPaneLayout
;
import
android.view.View
;
import
chat.rocket.android.LaunchUtil
;
import
chat.rocket.android.R
;
...
...
@@ -43,7 +42,6 @@ public class MainActivity extends AbstractAuthedActivity implements MainContract
setContentView
(
R
.
layout
.
activity_main
);
toolbar
=
(
RoomToolbar
)
findViewById
(
R
.
id
.
activity_main_toolbar
);
statusTicker
=
new
StatusTicker
();
setupSidebar
();
}
@Override
...
...
@@ -63,48 +61,6 @@ public class MainActivity extends AbstractAuthedActivity implements MainContract
super
.
onPause
();
}
private
void
setupSidebar
()
{
SlidingPaneLayout
pane
=
(
SlidingPaneLayout
)
findViewById
(
R
.
id
.
sliding_pane
);
if
(
pane
==
null
)
{
return
;
}
final
SlidingPaneLayout
subPane
=
(
SlidingPaneLayout
)
findViewById
(
R
.
id
.
sub_sliding_pane
);
pane
.
setPanelSlideListener
(
new
SlidingPaneLayout
.
SimplePanelSlideListener
()
{
@Override
public
void
onPanelClosed
(
View
panel
)
{
super
.
onPanelClosed
(
panel
);
if
(
subPane
!=
null
)
{
subPane
.
closePane
();
}
}
});
toolbar
.
setNavigationOnClickListener
(
view
->
{
if
(
pane
.
isSlideable
()
&&
!
pane
.
isOpen
())
{
pane
.
openPane
();
}
});
//ref: ActionBarDrawerToggle#setProgress
pane
.
setPanelSlideListener
(
new
SlidingPaneLayout
.
PanelSlideListener
()
{
@Override
public
void
onPanelSlide
(
View
panel
,
float
slideOffset
)
{
toolbar
.
setNavigationIconProgress
(
slideOffset
);
}
@Override
public
void
onPanelOpened
(
View
panel
)
{
toolbar
.
setNavigationIconVerticalMirror
(
true
);
}
@Override
public
void
onPanelClosed
(
View
panel
)
{
toolbar
.
setNavigationIconVerticalMirror
(
false
);
closeUserActionContainer
();
}
});
}
private
boolean
closeSidebarIfNeeded
()
{
// REMARK: Tablet UI doesn't have SlidingPane!
...
...
@@ -156,14 +112,6 @@ public class MainActivity extends AbstractAuthedActivity implements MainContract
.
commit
();
}
private
void
closeUserActionContainer
()
{
SidebarMainFragment
sidebarFragment
=
(
SidebarMainFragment
)
getSupportFragmentManager
()
.
findFragmentById
(
R
.
id
.
sidebar_fragment_container
);
if
(
sidebarFragment
!=
null
)
{
sidebarFragment
.
closeUserActionContainer
();
}
}
@Override
protected
void
onRoomIdUpdated
()
{
super
.
onRoomIdUpdated
();
...
...
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