Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
T
tg
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
tg
Commits
cd85857a
Commit
cd85857a
authored
Oct 01, 2015
by
V V
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
small fixes
parent
3bbd8e52
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
10 additions
and
0 deletions
+10
-0
interface.c
interface.c
+6
-0
json-tg.c
json-tg.c
+2
-0
lua-tg.c
lua-tg.c
+2
-0
No files found.
interface.c
View file @
cd85857a
...
...
@@ -1329,6 +1329,10 @@ void do_ ## act ## _ ## tp (struct command *command, int arg_num, struct arg arg
tgl_do_load_photo (TLS, M->media.photo, actf, ev);\
} else if (M->media.type == tgl_message_media_document) {\
tgl_do_load_document (TLS, M->media.document, actf, ev);\
} else if (M->media.type == tgl_message_media_video) {\
tgl_do_load_video (TLS, M->media.document, actf, ev);\
} else if (M->media.type == tgl_message_media_audio) {\
tgl_do_load_audio (TLS, M->media.document, actf, ev);\
} else if (M->media.type == tgl_message_media_document_encr) {\
tgl_do_load_encr_document (TLS, M->media.encr_document, actf, ev); \
} else if (M->media.type == tgl_message_media_webpage) {\
...
...
@@ -3551,6 +3555,8 @@ void print_media (struct in_ev *ev, struct tgl_message_media *M) {
}
return
;
case
tgl_message_media_document
:
case
tgl_message_media_audio
:
case
tgl_message_media_video
:
mprintf
(
ev
,
"["
);
assert
(
M
->
document
);
if
(
M
->
document
->
flags
&
TGLDF_IMAGE
)
{
...
...
json-tg.c
View file @
cd85857a
...
...
@@ -216,6 +216,8 @@ json_t *json_pack_media (struct tgl_message_media *M) {
}
break
;
case
tgl_message_media_document
:
case
tgl_message_media_audio
:
case
tgl_message_media_video
:
case
tgl_message_media_document_encr
:
assert
(
json_object_set
(
res
,
"type"
,
json_string
(
"document"
))
>=
0
);
break
;
...
...
lua-tg.c
View file @
cd85857a
...
...
@@ -284,6 +284,8 @@ void push_media (struct tgl_message_media *M) {
lua_add_string_field
(
"caption"
,
M
->
caption
);
break
;
case
tgl_message_media_document
:
case
tgl_message_media_audio
:
case
tgl_message_media_video
:
case
tgl_message_media_document_encr
:
lua_newtable
(
luaState
);
lua_add_string_field
(
"type"
,
"document"
);
...
...
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