Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
A
apk
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
apk
Commits
ee38ecec
Commit
ee38ecec
authored
May 19, 2014
by
DrKLO
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
fixed untouchable links
parent
e3594f37
Changes
2
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
5 additions
and
1 deletion
+5
-1
MessageObject.java
...roj/src/main/java/org/telegram/objects/MessageObject.java
+4
-0
ChatMessageCell.java
.../src/main/java/org/telegram/ui/Cells/ChatMessageCell.java
+1
-1
No files found.
TMessagesProj/src/main/java/org/telegram/objects/MessageObject.java
View file @
ee38ecec
...
@@ -425,6 +425,7 @@ public class MessageObject {
...
@@ -425,6 +425,7 @@ public class MessageObject {
int
blocksCount
=
(
int
)
Math
.
ceil
((
float
)
linesCount
/
LINES_PER_BLOCK
);
int
blocksCount
=
(
int
)
Math
.
ceil
((
float
)
linesCount
/
LINES_PER_BLOCK
);
int
linesOffset
=
0
;
int
linesOffset
=
0
;
float
prevOffset
=
0
;
for
(
int
a
=
0
;
a
<
blocksCount
;
a
++)
{
for
(
int
a
=
0
;
a
<
blocksCount
;
a
++)
{
...
@@ -449,6 +450,9 @@ public class MessageObject {
...
@@ -449,6 +450,9 @@ public class MessageObject {
block
.
textYOffset
=
textLayout
.
getLineTop
(
linesOffset
);
block
.
textYOffset
=
textLayout
.
getLineTop
(
linesOffset
);
if
(
a
!=
blocksCount
-
1
)
{
if
(
a
!=
blocksCount
-
1
)
{
blockHeight
=
Math
.
min
(
blockHeight
,
block
.
textLayout
.
getHeight
());
blockHeight
=
Math
.
min
(
blockHeight
,
block
.
textLayout
.
getHeight
());
prevOffset
=
block
.
textYOffset
;
}
else
{
blockHeight
=
Math
.
min
(
blockHeight
,
(
int
)(
block
.
textYOffset
-
prevOffset
));
}
}
}
catch
(
Exception
e
)
{
}
catch
(
Exception
e
)
{
FileLog
.
e
(
"tmessages"
,
e
);
FileLog
.
e
(
"tmessages"
,
e
);
...
...
TMessagesProj/src/main/java/org/telegram/ui/Cells/ChatMessageCell.java
View file @
ee38ecec
...
@@ -40,8 +40,8 @@ public class ChatMessageCell extends ChatBaseCell {
...
@@ -40,8 +40,8 @@ public class ChatMessageCell extends ChatBaseCell {
int
x
=
(
int
)
event
.
getX
();
int
x
=
(
int
)
event
.
getX
();
int
y
=
(
int
)
event
.
getY
();
int
y
=
(
int
)
event
.
getY
();
if
(
x
>=
textX
&&
y
>=
textY
&&
x
<=
textX
+
currentMessageObject
.
textWidth
&&
y
<=
textY
+
currentMessageObject
.
textHeight
)
{
if
(
x
>=
textX
&&
y
>=
textY
&&
x
<=
textX
+
currentMessageObject
.
textWidth
&&
y
<=
textY
+
currentMessageObject
.
textHeight
)
{
int
blockNum
=
Math
.
max
(
0
,
y
/
currentMessageObject
.
blockHeight
);
y
-=
textY
;
y
-=
textY
;
int
blockNum
=
Math
.
max
(
0
,
y
/
currentMessageObject
.
blockHeight
);
if
(
blockNum
<
currentMessageObject
.
textLayoutBlocks
.
size
())
{
if
(
blockNum
<
currentMessageObject
.
textLayoutBlocks
.
size
())
{
MessageObject
.
TextLayoutBlock
block
=
currentMessageObject
.
textLayoutBlocks
.
get
(
blockNum
);
MessageObject
.
TextLayoutBlock
block
=
currentMessageObject
.
textLayoutBlocks
.
get
(
blockNum
);
x
-=
textX
-
(
int
)
Math
.
ceil
(
block
.
textXOffset
);
x
-=
textX
-
(
int
)
Math
.
ceil
(
block
.
textXOffset
);
...
...
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