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
fa07e7ff
Commit
fa07e7ff
authored
Jul 27, 2017
by
Filipe de Lima Brito
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Update files to follow the code style.
parent
bff56d0d
Changes
4
Show whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
23 additions
and
23 deletions
+23
-23
MessageFormLayout.java
...chat/rocket/android/widget/message/MessageFormLayout.java
+13
-13
top_shadow.xml
...chat-android-widgets/src/main/res/drawable/top_shadow.xml
+1
-1
message_composer.xml
...-android-widgets/src/main/res/layout/message_composer.xml
+6
-6
colors.xml
rocket-chat-android-widgets/src/main/res/values/colors.xml
+3
-3
No files found.
rocket-chat-android-widgets/src/main/java/chat/rocket/android/widget/message/MessageFormLayout.java
View file @
fa07e7ff
...
...
@@ -23,8 +23,8 @@ public class MessageFormLayout extends LinearLayout {
protected
ViewGroup
composer
;
private
ImageButton
attach
mentImage
Button
;
private
ImageButton
send
Image
Button
;
private
ImageButton
attachButton
;
private
ImageButton
sendButton
;
private
ExtraActionSelectionClickListener
extraActionSelectionClickListener
;
private
SubmitTextListener
submitTextListener
;
...
...
@@ -55,18 +55,18 @@ public class MessageFormLayout extends LinearLayout {
composer
=
(
ViewGroup
)
LayoutInflater
.
from
(
getContext
())
.
inflate
(
R
.
layout
.
message_composer
,
this
,
false
);
attach
mentImageButton
=
composer
.
findViewById
(
R
.
id
.
attachmentImageButton
);
attach
Button
=
composer
.
findViewById
(
R
.
id
.
button_attach
);
attach
mentImage
Button
.
setOnClickListener
(
new
OnClickListener
()
{
attachButton
.
setOnClickListener
(
new
OnClickListener
()
{
@Override
public
void
onClick
(
View
view
)
{
onExtraActionSelectionClick
();
}
});
send
ImageButton
=
composer
.
findViewById
(
R
.
id
.
sendImageButton
);
send
Button
=
composer
.
findViewById
(
R
.
id
.
button_send
);
send
Image
Button
.
setOnClickListener
(
new
OnClickListener
()
{
sendButton
.
setOnClickListener
(
new
OnClickListener
()
{
@Override
public
void
onClick
(
View
view
)
{
String
messageText
=
getText
();
...
...
@@ -76,9 +76,9 @@ public class MessageFormLayout extends LinearLayout {
}
});
send
Image
Button
.
setScaleX
(
0
);
send
Image
Button
.
setScaleY
(
0
);
send
Image
Button
.
setVisibility
(
GONE
);
sendButton
.
setScaleX
(
0
);
sendButton
.
setScaleY
(
0
);
sendButton
.
setVisibility
(
GONE
);
ImageKeyboardEditText
editText
=
composer
.
findViewById
(
R
.
id
.
editor
);
...
...
@@ -94,11 +94,11 @@ public class MessageFormLayout extends LinearLayout {
@Override
public
void
afterTextChanged
(
Editable
s
)
{
if
(
TextUtils
.
getTrimmedLength
(
s
)
>
0
)
{
animateHide
(
attach
mentImage
Button
);
animateShow
(
send
Image
Button
);
animateHide
(
attachButton
);
animateShow
(
sendButton
);
}
else
{
animateShow
(
attach
mentImage
Button
);
animateHide
(
send
Image
Button
);
animateShow
(
attachButton
);
animateHide
(
sendButton
);
}
}
});
...
...
rocket-chat-android-widgets/src/main/res/drawable/top_shadow.xml
View file @
fa07e7ff
...
...
@@ -2,7 +2,7 @@
<layer-list
xmlns:android=
"http://schemas.android.com/apk/res/android"
>
<item>
<shape
android:shape=
"rectangle"
>
<solid
android:color=
"@color/color
S
hadow"
/>
<solid
android:color=
"@color/color
_s
hadow"
/>
</shape>
</item>
...
...
rocket-chat-android-widgets/src/main/res/layout/message_composer.xml
View file @
fa07e7ff
...
...
@@ -22,11 +22,11 @@
android:background=
"@null"
app:layout_constraintTop_toTopOf=
"parent"
app:layout_constraintLeft_toLeftOf=
"parent"
app:layout_constraintRight_toLeftOf=
"@+id/
imageButtonC
ontainer"
app:layout_constraintRight_toLeftOf=
"@+id/
c
ontainer"
app:layout_constraintBottom_toBottomOf=
"parent"
/>
<android.support.constraint.ConstraintLayout
android:id=
"@+id/
imageButtonC
ontainer"
android:id=
"@+id/
c
ontainer"
android:layout_width=
"wrap_content"
android:layout_height=
"wrap_content"
android:layout_marginLeft=
"16dp"
...
...
@@ -39,18 +39,18 @@
app:layout_constraintBottom_toBottomOf=
"@+id/editor"
>
<ImageButton
android:id=
"@+id/
attachmentImageButton
"
android:id=
"@+id/
button_attach
"
android:layout_width=
"wrap_content"
android:layout_height=
"wrap_content"
android:tint=
"@color/color
DefaultMessageComposerIcon
"
android:tint=
"@color/color
_icon_composer
"
app:srcCompat=
"@drawable/ic_attach_file_black_24dp"
android:background=
"?attr/selectableItemBackgroundBorderless"
/>
<ImageButton
android:id=
"@+id/
sendImageButton
"
android:id=
"@+id/
button_send
"
android:layout_width=
"wrap_content"
android:layout_height=
"wrap_content"
android:tint=
"@color/color
A
ccent"
android:tint=
"@color/color
_a
ccent"
app:srcCompat=
"@drawable/ic_send_black_24dp"
android:background=
"?attr/selectableItemBackgroundBorderless"
/>
</android.support.constraint.ConstraintLayout>
...
...
rocket-chat-android-widgets/src/main/res/values/colors.xml
View file @
fa07e7ff
<?xml version="1.0" encoding="utf-8"?>
<resources>
<color
name=
"color
A
ccent"
>
#FF2D91FA
</color>
<color
name=
"color
S
hadow"
>
#FFE6E6E7
</color>
<color
name=
"color
DefaultMessageComposerIcon
"
>
#FFA8A8A8
</color>
<color
name=
"color
_a
ccent"
>
#FF2D91FA
</color>
<color
name=
"color
_s
hadow"
>
#FFE6E6E7
</color>
<color
name=
"color
_icon_composer
"
>
#FFA8A8A8
</color>
</resources>
\ No newline at end of file
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