Compare commits

...

391 Commits

Author SHA1 Message Date
2323c3cac5 Include mastodon default config file on builds 2022-12-06 10:06:27 -06:00
e90c370e73 Add secrets on build stages 2022-12-06 09:12:09 -06:00
cadcc56182 Updated changelog 2022-12-05 16:55:06 -06:00
619f58ad90 Updated changelog 2022-12-05 16:51:57 -06:00
c480554e01 Merge branch 'next-gen' of gitlab.mcvsoftware.com:twblue/twblue into next-gen 2022-12-05 03:00:57 -06:00
6da81a9734 Get offset from local user timezone as opposed to call get_settings on twitter's side 2022-12-05 03:00:03 -06:00
b559726535 Update method to determine custom character limit to detect changes in mastodon servers 2022-11-30 11:19:51 -06:00
768f0bc396 Merge pull request #496 from MCV-Software/mastodon
Initial Mastodon Support
2022-11-25 17:50:08 -06:00
5bbf069d61 Set updated statuses also in GUI 2022-11-25 17:43:03 -06:00
d177ef5be2 Initial support for edited statuses in Streaming API. Only Works in invisible interface for now 2022-11-25 17:30:57 -06:00
b6dd539dc6 Hide VLC log info 2022-11-25 15:29:21 -06:00
fabca1207d Fixed issue when cleaning a buffer 2022-11-24 16:36:08 -06:00
bf4c7ff7c7 Make sure item ID is included when composing a dm in mastodon 2022-11-24 15:28:39 -06:00
8d2fb59ba8 Added some fixes 2022-11-24 15:22:09 -06:00
b7497791b4 Update buffer removal code. Should be able to remove user search buffers 2022-11-21 22:09:40 -06:00
48730ead63 Keep sensitive content tag when replying to posts 2022-11-21 19:36:34 -06:00
98ecd000a9 change default soundpack for mastodon sessions and hide federated timeline by default 2022-11-21 17:28:23 -06:00
4a9098021f Avoid playing new dm's sound for now 2022-11-20 15:01:15 -06:00
8850e5fdde Removed unneeded code and fixed small typos 2022-11-20 14:54:10 -06:00
e42bd85274 Fixed shortcut to open followers timelines in the dialog 2022-11-20 13:28:43 -06:00
d3914a4e34 Implemented user timelines (statuses, followers & following). Limited support due to API 2022-11-20 02:23:12 -06:00
73de8d4f49 Updated followers sound to match the correct sounds used for twitter sessions 2022-11-19 19:37:10 -06:00
ce458a8d4d Added direct messages and followers to streaming API implementation 2022-11-19 19:36:21 -06:00
149ce51f49 early support to user streaming events 2022-11-18 16:29:53 -06:00
2fe9c35c0b Add pubsub events by using twitter's namespace to separate services 2022-11-18 13:41:12 -06:00
39fb5b4830 fixed visibility settings when sending replies 2022-11-18 13:40:02 -06:00
71ca547abe Implemented user searches 2022-11-18 10:28:45 -06:00
1c5c1067e6 Fixed KeystrokeEditor's GUI 2022-11-17 17:37:44 -06:00
df4d3eb0e6 Fix Issue that avoids removing trending topic buffers 2022-11-17 17:27:41 -06:00
927bbae1be bind user actions button to its function in user buffers' GUI 2022-11-17 16:59:48 -06:00
cbc4fd0632 Added buttons for toggling favorites and bookmarks in base buffer's GUI 2022-11-17 16:57:49 -06:00
10d4d47a17 Handle errors in authorisation for both Twitter and mastodon 2022-11-17 16:19:47 -06:00
52d64d86d8 Add sessions only after authorise returns True 2022-11-17 16:19:03 -06:00
2ab61ebee6 Create session folder only if the session is actually created successfully (authorized) 2022-11-17 16:18:30 -06:00
3ad01d1ab0 Fixed a typo 2022-11-17 12:44:28 -06:00
7835e09c5b Added oauth authorisation to mastodon session 2022-11-16 15:33:27 -06:00
4c5d2b5e04 Update persons default template 2022-11-16 13:42:31 -06:00
8f72ee97c9 Replace 'toot' term to follow mastodon changes 2022-11-16 13:28:45 -06:00
aebdcae9cf Fixed some buffer names 2022-11-16 12:55:35 -06:00
3b5ef02def fixed small name conflict in buffers 2022-11-16 12:51:58 -06:00
35599ee0ef Add newline character after every image description parsed 2022-11-16 12:40:52 -06:00
6e03578e86 Fixed lists 2022-11-16 12:35:19 -06:00
7cbf873db5 Include date and client in conversation list GUI 2022-11-16 11:40:23 -06:00
fefd88b71c Create valid account buffers even when session cannot login to the network (works for ignored sessions) 2022-11-16 11:01:52 -06:00
7c80c9d842 Improve conversation replies 2022-11-16 10:31:17 -06:00
f5e52c6387 Honor custom character limit if reported by the instance 2022-11-16 10:06:14 -06:00
4c43f82b60 changed import of twitter text parser 2022-11-15 17:23:01 -06:00
2caaaa9d87 Fix: LogOut from sessions 2022-11-15 16:15:09 -06:00
3fa39c712e Set a mastodon version for the API 2022-11-15 16:13:16 -06:00
252a93f82d save list buffers after being created 2022-11-15 16:12:49 -06:00
f5328379e8 Fixed list buffer creation 2022-11-15 13:31:11 -06:00
2e8c8c6db4 Rework sessions to be handled with unique names 2022-11-15 11:54:59 -06:00
862dbd0b8a Change session name as identifiable key for every session in TWblue 2022-11-14 17:51:27 -06:00
120da217f5 Implemented userActions for mastodon sessions 2022-11-14 12:39:32 -06:00
035de92496 Added user buffers (buffers for followers, following, blocked and muted users for now) 2022-11-13 22:17:28 -06:00
2a0e73ad33 Use the same visibility when replying to toots 2022-11-12 22:32:31 -06:00
701a557357 Add support to retrieve more conversations if needed. Sort conversation properly on updates 2022-11-12 21:28:49 -06:00
de1d94e679 update toot from server before displaying item 2022-11-12 15:26:34 -06:00
64d5b7e684 Changed mentionned people for direct in toots' visibility info 2022-11-12 15:16:53 -06:00
2c9048618f Added visibility as a variable template for toots 2022-11-12 15:16:20 -06:00
José Manuel Delicado Alcolea
d66f4a2640 Updated Windows dependencies. Switching to Python 3.10.8 2022-11-12 20:29:02 +01:00
bfbb280c27 Fixed update in mentions 2022-11-12 13:06:46 -06:00
cad7c9a9fd Added conversationListBuffer GUI 2022-11-12 13:06:03 -06:00
81ff530a71 Added initial support for direct messages, users need to open conversations for every dm 2022-11-12 11:20:16 -06:00
39fc982665 Added conversations buffer 2022-11-12 09:16:35 -06:00
803f5fbe89 Fixed a few things in tootDialog 2022-11-11 17:32:31 -06:00
0d1d4c887d Added bookmarks buffer 2022-11-11 17:25:04 -06:00
f8f13be6d3 Updated mastodon default config (again) 2022-11-11 17:20:32 -06:00
5f645508ba Added mentions buffer (filters notifications by mention and extract toots from them) 2022-11-11 17:12:03 -06:00
3a3cb3963c Allows to add content warnings when writing a toot 2022-11-11 16:21:15 -06:00
2c298577cc Re-added toot dialog to make it more compatible with mastodon. Added visibility and audio attachments 2022-11-11 15:51:16 -06:00
97815f807a get description only for images, for now 2022-11-11 15:05:56 -06:00
f24f97baae Removed code from our html parser 2022-11-11 15:04:14 -06:00
2a10f029f0 Added basic toot viewing (untested yet) 2022-11-10 17:54:38 -06:00
3deffa57de Added content warnings to templates as $safe_text. Content warnings will be shown by default on GUI for now 2022-11-10 15:32:49 -06:00
d6985be896 Update mastodon default config 2022-11-10 11:57:30 -06:00
0aad2f0ab3 Improved html parsing for toots. Remove Tags from URLList 2022-11-10 10:01:39 -06:00
f151d6554d Added mastodon buffer menus 2022-11-10 07:56:20 -06:00
62d6ae2277 Added favorites buffer, and actions to add, remove and toggle favorite for toots 2022-11-09 17:08:48 -06:00
b405e384c8 Added toot deletion and opening URLS in the browser 2022-11-09 15:52:18 -06:00
7aa986163b Allow to open bosted toots in web browser 2022-11-09 15:23:07 -06:00
59409e61a5 Added playback of audio and video attachments in toots 2022-11-09 13:07:59 -06:00
edbc74262a change character max value for new toot dialog 2022-11-09 12:45:56 -06:00
e07efa46b3 when replying to a conversation, change GUI accordingly and retain original toot's visibility 2022-11-09 11:14:48 -06:00
bedb2e2a4f Hide boost buttons and menu item when focus is in a toot part of a conversation 2022-11-09 11:03:23 -06:00
96b5eec8e0 Added support for creating conversations 2022-11-09 10:59:25 -06:00
c6433d8655 Fixed reply and toot things to make it work properly 2022-11-09 10:20:14 -06:00
c0654658b5 Added indications when there are audio, video, photos or gifvs in media attachments 2022-11-09 09:09:37 -06:00
d71d3695eb Added image descriptions to template system 2022-11-09 08:54:47 -06:00
4b6a7c5d83 Added loading more items in mastodon buffers and enabled buffer buttons for toot, reply and boost 2022-11-09 08:42:56 -06:00
368e089639 Added toot writing and replies 2022-11-08 17:53:59 -06:00
33647da6e8 If user has no display_name set, let's show mastodon username instead 2022-11-08 15:46:16 -06:00
ca39db649b Added sent toots buffer 2022-11-08 15:45:12 -06:00
07dc813cb6 Fixed a small typo 2022-11-08 15:16:01 -06:00
a852a429f4 Implemented boost for toot buffers 2022-11-08 13:49:43 -06:00
1e3a0d9b2e mastodon: Avoid playing sounds on first buffer start 2022-11-08 13:49:15 -06:00
9959ac24d9 Implemented retoots 2022-11-08 13:22:27 -06:00
90f9f18deb added missing settings for mastodon's config 2022-11-08 13:21:45 -06:00
6983d11b73 Added some dialogs for future use 2022-11-08 13:18:04 -06:00
cd5b71a26e fixed small typo 2022-11-08 12:45:40 -06:00
aa3ca82f25 Added buffers on account creation (home, local and federated timelines). Most of functions don't work, just displaying items 2022-11-08 12:41:04 -06:00
bf9b8a4f46 Added mastodon baseBuffer controller 2022-11-08 12:39:04 -06:00
2be460b662 Add templates and buffer order for mastodon default config 2022-11-08 12:21:39 -06:00
1d4057ac5b Added compose function for people in mastodon instances 2022-11-08 12:21:03 -06:00
b9731a3c75 Fixed typos in mastodon buffer GUI 2022-11-08 12:20:11 -06:00
d53decb165 added order_buffer method to sort toots in database 2022-11-08 12:19:41 -06:00
02b8330ca0 Added templates for toots and persons 2022-11-08 12:19:05 -06:00
12046c1f56 Updated compose function for toots 2022-11-08 08:59:09 -06:00
6f69426f03 Fixed more conflicts 2022-11-08 08:48:35 -06:00
c8c242a27f Fixed merge conflicts with next-gen 2022-11-08 08:35:01 -06:00
60daa548ca Added util to parse mastodon toots (very basic, not yet implemented) 2022-11-07 17:13:03 -06:00
40989a54ed cleaned up some imports 2022-11-07 16:15:04 -06:00
87f2976419 moved searches to Twitter handler 2022-11-07 16:06:52 -06:00
b6b81e2b36 Move almost everything related to Twitter to handler 2022-11-07 15:55:28 -06:00
dfcd63b9b6 Moved timelines for users, likes, followers, following and conversations to Twitter handler 2022-11-07 13:55:08 -06:00
23af944fba Moved some interactions with buffers from main controller to the buffer classes themselves 2022-11-07 13:02:54 -06:00
cf9add1fc9 Added empty function view_item to base buffer 2022-11-07 13:01:58 -06:00
a63f19a70f Separate global settings and account settings into two diferent modules so implementing other services will be way easier 2022-11-07 12:27:23 -06:00
8ad266ad1b Moved filters, list features, user actions, user aliases and account config to twitter handler 2022-11-07 12:26:58 -06:00
b593071364 Added empty check_streams to mastodon session so it won't raise errors for a while 2022-11-07 12:24:56 -06:00
0e814a765a Fixed small issue when attempting to apply filters by language 2022-11-07 11:28:42 -06:00
2c7eab60a8 Separate most Twitter features in their own controller so it might be easier to implement those in the handler 2022-11-07 10:25:19 -06:00
d43738a2ec Added base mastodon controller 2022-11-07 09:54:09 -06:00
0f885712b6 Remove unused import in Twitter controller 2022-11-07 09:50:01 -06:00
14a10989e5 Update controller 2022-11-07 09:17:08 -06:00
d5253f651b Merge branch 'next-gen' of gitlab.mcvsoftware.com:twblue/twblue into next-gen 2022-11-07 08:36:58 -06:00
31e901b000 Fixed more locale conflicts 2022-11-06 16:10:56 -06:00
26e7ff009f fixed locales conflicts 2022-11-06 16:07:45 -06:00
1ded773e84 Removed some platform checks 2022-11-03 17:11:13 -06:00
b8637ba8ca Update locales 2022-11-03 11:38:56 -06:00
4dc4f46b84 Removed some platform unused code 2022-11-03 11:34:21 -06:00
e00ec84df3 Updated changelog 2022-11-03 09:52:52 -06:00
8dd122cfb2 Updated ReadMe regarding python version and appkeys 2022-11-03 09:12:41 -06:00
dcfacf8cdd Merge pull request #495 from MCV-Software/python310
Increase Python version to 3.10. Closes #493
2022-11-03 08:53:20 -06:00
bc1522833c Removed appkeys from public repo 2022-11-03 08:47:15 -06:00
4b7382e61f Set python versions to 3.10.8 in CI config File and use a custom WXPython for 32-bit support 2022-11-02 09:42:01 -06:00
585d8e2b0c Removed reference to six and futures as Pytohn 3.10 doesn't need those 2022-11-02 09:27:09 -06:00
f34829d72d Merge branch 'weblate-twblue-twblue' into 'next-gen'
Translations update from Translations hub

See merge request twblue/twblue!9
2022-11-02 15:16:18 +00:00
Steffen Schultz
fd1d60b815 Translated using Weblate (German)
Currently translated at 100.0% (258 of 258 strings)

Translation: TWBlue/changelog
Translate-URL: https://weblate.mcvsoftware.com/projects/twblue/changelog/de/
2022-10-12 04:23:53 -05:00
Steffen Schultz
31e194a038 Translated using Weblate (German)
Currently translated at 100.0% (267 of 267 strings)

Translation: TWBlue/documentation
Translate-URL: https://weblate.mcvsoftware.com/projects/twblue/documentation/de/
2022-10-05 08:23:54 -05:00
Steffen Schultz
e25712920a Translated using Weblate (German)
Currently translated at 100.0% (796 of 796 strings)

Translation: TWBlue/TWBlue
Translate-URL: https://weblate.mcvsoftware.com/projects/twblue/twblue/de/
2022-10-05 08:23:53 -05:00
Steffen Schultz
27867a1961 Added translation using Weblate (German) 2022-10-04 07:47:50 -05:00
Steffen Schultz
1425dcd313 Added translation using Weblate (German) 2022-10-04 06:02:54 -05:00
Riku
b9cff1a9c9 Translated using Weblate (Japanese)
Currently translated at 100.0% (796 of 796 strings)

Translation: TWBlue/TWBlue
Translate-URL: https://weblate.mcvsoftware.com/projects/twblue/twblue/ja/
2022-09-09 01:02:02 -05:00
fc1ed54963 Merge branch 'weblate-twblue-twblue' into 'next-gen'
Translations update from Translations hub

See merge request twblue/twblue!8
2022-09-06 18:13:29 +00:00
Jonas S. Marques
442abe82db Translated using Weblate (Portuguese)
Currently translated at 90.5% (721 of 796 strings)

Translation: TWBlue/TWBlue
Translate-URL: https://weblate.mcvsoftware.com/projects/twblue/twblue/pt/
2022-09-03 19:02:00 -05:00
1b693cd798 Merge branch 'weblate-twblue-twblue' into 'next-gen'
Translations update from Translations hub

See merge request twblue/twblue!7
2022-09-02 22:01:51 +00:00
zvonimir stanecic
8426d8851f Translated using Weblate (Croatian)
Currently translated at 95.6% (761 of 796 strings)

Translation: TWBlue/TWBlue
Translate-URL: https://weblate.mcvsoftware.com/projects/twblue/twblue/hr/
2022-08-29 12:03:36 -05:00
Corentin Bacqué-Cazenave
eca5aa7bfe Translated using Weblate (French)
Currently translated at 100.0% (796 of 796 strings)

Translation: TWBlue/TWBlue
Translate-URL: https://weblate.mcvsoftware.com/projects/twblue/twblue/fr/
2022-08-29 12:03:35 -05:00
8116d98691 Fix wx to 4.1.1 for now 2022-08-28 05:52:51 -05:00
1b498a99bd Updated version info 2022-08-28 05:00:54 -05:00
1a4e594549 Merge branch 'weblate-twblue-twblue' into 'next-gen'
Translations update from Translations hub

See merge request twblue/twblue!6
2022-08-25 22:00:58 +00:00
zvonimir stanecic
2b0172f02f Translated using Weblate (Croatian)
Currently translated at 92.0% (733 of 796 strings)

Translation: TWBlue/TWBlue
Translate-URL: https://weblate.mcvsoftware.com/projects/twblue/twblue/hr/
2022-08-25 13:09:14 -05:00
2d2c84fefe Translated using Weblate (Spanish)
Currently translated at 100.0% (258 of 258 strings)

Translation: TWBlue/changelog
Translate-URL: https://weblate.mcvsoftware.com/projects/twblue/changelog/es/
2022-08-25 13:09:14 -05:00
zvonimir stanecic
0bef872070 Translated using Weblate (Croatian)
Currently translated at 88.3% (703 of 796 strings)

Translation: TWBlue/TWBlue
Translate-URL: https://weblate.mcvsoftware.com/projects/twblue/twblue/hr/
2022-08-25 13:09:14 -05:00
b233842f5c Translated using Weblate (Spanish)
Currently translated at 100.0% (796 of 796 strings)

Translation: TWBlue/TWBlue
Translate-URL: https://weblate.mcvsoftware.com/projects/twblue/twblue/es/
2022-08-25 13:09:14 -05:00
0202b704da Merge branch 'next-gen' of gitlab.mcvsoftware.com:twblue/twblue into next-gen 2022-08-25 13:08:24 -05:00
7d3ac47d55 correct name in some locale folders to make it standard 2022-08-25 12:56:47 -05:00
e2ba61701f Merge branch 'weblate-twblue-twblue' into 'next-gen'
Translations update from Translations hub

See merge request twblue/twblue!5
2022-08-24 16:59:23 +00:00
Weblate
8032f5cf75 Update translation files
Updated by "Update PO files to match POT (msgmerge)" hook in Weblate.

Translation: TWBlue/changelog
Translate-URL: https://weblate.mcvsoftware.com/projects/twblue/changelog/
2022-08-24 11:32:59 -05:00
Weblate
96f5d0e426 Update translation files
Updated by "Update PO files to match POT (msgmerge)" hook in Weblate.

Translation: TWBlue/changelog
Translate-URL: https://weblate.mcvsoftware.com/projects/twblue/changelog/
2022-08-24 11:32:58 -05:00
0ba71c985d Translated using Weblate (Spanish)
Currently translated at 100.0% (234 of 234 strings)

Translation: TWBlue/changelog
Translate-URL: https://weblate.mcvsoftware.com/projects/twblue/changelog/es/
2022-08-24 11:32:58 -05:00
c6cbe3360b Restart streaming in certain changes to followed/muted people 2022-08-24 11:32:06 -05:00
ac80e039b2 Updated template files for documentation translations 2022-08-23 16:27:30 -05:00
2039597098 Removes properly new twitter quote statuses on templating system 2022-08-23 11:51:37 -05:00
74fd4bfadf Removed unneeded code 2022-08-23 11:34:13 -05:00
c374663b7c Merge branch 'weblate-twblue-twblue' into 'next-gen'
Translations update from Translations hub

See merge request twblue/twblue!4
2022-08-22 20:41:21 +00:00
0f3d7d8747 Translated using Weblate (Spanish)
Currently translated at 99.7% (794 of 796 strings)

Translation: TWBlue/TWBlue
Translate-URL: https://weblate.mcvsoftware.com/projects/twblue/twblue/es/
2022-08-22 15:40:45 -05:00
0a395af3a9 Updated changelog 2022-08-22 15:40:01 -05:00
José Manuel Delicado
f181c5d1cd Merge pull request #489 from riku22/japanese_translation
Update Japanese translation
2022-08-20 09:39:27 +02:00
riku
204b9ebc02 Update Japanese translation 2022-08-20 07:22:36 +09:00
0a479b55ed Merge branch 'weblate-twblue-twblue' into 'next-gen'
Translations update from Translations hub

See merge request twblue/twblue!3
2022-08-19 15:26:42 +00:00
Weblate
eb0c3a650a Update translation files
Updated by "Update PO files to match POT (msgmerge)" hook in Weblate.

Translation: TWBlue/TWBlue
Translate-URL: https://weblate.mcvsoftware.com/projects/twblue/twblue/
2022-08-18 12:17:12 -05:00
829506acf5 Updated main POT file 2022-08-18 12:05:38 -05:00
14ee87b25a Merge pull request #488 from nidza07/SerbianTranslation
Updated Serbian translation
2022-08-18 10:18:29 -05:00
ebdf2e21bb Merge pull request #487 from CoBC/fr_180822
Update French interface
2022-08-18 10:17:30 -05:00
Nikola Jovic
30a944fc61 Updated Serbian translation 2022-08-18 16:09:26 +02:00
Corentin Bacqué-Cazenave
5c0af2fc01 Update French interface 2022-08-18 15:33:02 +02:00
e470498e56 updated locales to make dates more standard as babel requires it to work properly 2022-08-17 10:55:55 -05:00
fa2d2d9d78 Improved sorting in conversation buffers 2022-08-17 10:09:32 -05:00
b9794806d7 Display error when attempting to open a TL for an unauthorized user. Closes #485 2022-08-16 17:11:50 -05:00
1e686cffba Merge pull request #486 from MCV-Software/autocomplete_redesign
Changes in user autocompletion feature. Closes #466. Closes #368
2022-08-03 11:56:13 -05:00
0f624c7dbe Updated changelog 2022-08-03 11:24:26 -05:00
76a5c960e5 Added user autocompletion functionality to some dialogs. Closes #466 2022-08-03 11:12:23 -05:00
aab8aafefc Introduced user selector controller for implementing user autocompletion in wxUI.dialogs.utils.selectUserDialog 2022-08-03 11:11:31 -05:00
015cf9eca3 Fixed small typo 2022-08-03 10:36:54 -05:00
769436abf7 Updated menu to avoid using deprecated wx methods 2022-08-03 09:53:35 -05:00
b2da25dd61 Updated code on controllers for changes in user autocompletion module 2022-08-03 09:52:09 -05:00
03f59064d5 Report amount of imported users after scan 2022-08-03 09:39:45 -05:00
9afd6774f2 Added a new and custom progress dialog for user scanning 2022-08-03 09:37:18 -05:00
a1929ff1d3 Make sure Show() is called for progress dialog 2022-08-02 09:06:46 -05:00
4b627a13ff Start a small refactor in GUI code 2022-07-29 17:54:34 -05:00
f9f7a32f90 Bind manage button with code to manage autocompletion db 2022-07-29 17:37:28 -05:00
f01ad5abb7 Return on exception 2022-07-29 17:27:48 -05:00
6fcd0274a9 Added exception handling to scan for users 2022-07-29 13:30:43 -05:00
654b34c8e1 Cleaned some unneeded dialogs 2022-07-29 12:11:27 -05:00
02e1793d08 cleaned scan controller and made progress dialog to work 2022-07-29 12:11:03 -05:00
6e80b320c9 Improved documentation in some classes 2022-07-29 12:08:05 -05:00
83c9db573e Added first stage of refactor for autocompletion users 2022-07-08 11:39:14 -05:00
3aee5e8900 Merge pull request #482 from riku22/japanese_translation
Update Japanese translation
2022-07-07 16:27:40 -05:00
riku
a88af08181 Update Japanese translation 2022-07-08 05:19:51 +09:00
79098cc730 Updated changelog 2022-07-07 11:17:57 -05:00
d12e3aa335 Merge pull request #480 from CoBC/fr_070722
Update French interface
2022-07-07 08:56:48 -05:00
Corentin Bacqué-Cazenave
1d8fcf9166 Update Frenchinterface 2022-07-07 15:45:38 +02:00
3702405f8c Merge pull request #479 from CoBC/tr_relationship
Add "Relationship" to translation
2022-07-07 08:41:40 -05:00
7ce55c427e Merge pull request #478 from nidza07/SerbianTranslation
Updated Serbian translation
2022-07-07 08:40:19 -05:00
508b798bee Merge pull request #477 from CoBC/fr_160622
Update french interface
2022-07-07 08:39:37 -05:00
53ac43a8b2 Merge pull request #476 from jeremyp3/issue-420
add shortcut for find dialog in Windows 10 and Windows 11 keymap fix #420
2022-07-07 08:38:18 -05:00
Corentin Bacqué-Cazenave
22b8d91612 Add "Relationship" to translation 2022-06-23 10:27:09 +02:00
Nikola Jovic
4f619759e6 Updated Serbian translation 2022-06-20 14:58:37 +02:00
Corentin Bacqué-Cazenave
0ac6f49379 Update french interface 2022-06-16 08:57:36 +02:00
Jeremyp3
b332902b91 add shortcut for find dialog in Windows 10 and Windows 11 keymap fix #420 2022-06-11 15:45:04 +02:00
a138b8c02e Started to document autocompltion users module 2022-05-26 05:45:46 -05:00
c89dff053d fixed error when sending a tweet to someone in any people buffer 2022-05-26 05:26:02 -05:00
018095752b Merge branch 'next-gen' of github.com:mcv-software/twblue into next-gen 2022-05-21 20:16:03 -05:00
bd90902e3b Fixed alternative updatefile 2022-05-21 20:15:36 -05:00
8bf9c6519e Improve text for direct messages when displayed via the templates system 2022-05-20 12:22:25 -05:00
bed8e26204 Fixed loading of other users lists. Fixes #465 2022-05-13 13:33:10 -05:00
fa9ebea836 Remove issue reporting dialogs as we no longer use mantis 2022-05-13 13:22:52 -05:00
be8d82a65f Merge pull request #471 from MCV-Software/demoji-support
Added setting to hide emojis in usernames
2022-05-13 13:16:02 -05:00
ab979e2623 Added setting to hide emojis in usernames 2022-05-13 13:04:12 -05:00
20ad268e5a Merge pull request #469 from riku22/fix_edit_person_template
Fix edit person template
2022-04-29 08:15:49 -05:00
riku
83c9a7f0f9 Fix edit person template 2022-04-29 21:45:06 +09:00
9d90d91cfd Merge branch 'next-gen' of github.com:mcv-software/twblue into next-gen 2022-04-06 15:13:22 -05:00
bbf1356c89 Fixed an error when parsing retweets containing quoted tweets in streaming API 2022-04-06 15:11:55 -05:00
485b4c3c6c Code cleanup 2022-03-24 10:39:20 -06:00
b35cdbd7b4 Added handlers to map features from different networks 2022-03-24 10:37:50 -06:00
67d15d8fe1 Merge pull request #462 from jonasmarques/next-gen
Fixed UTF8 display for translation  of reply to dialog
2022-02-25 11:23:26 -06:00
jonasmarques
3bd274db0c Fixed UTF8 display for translation of reply to dialog
The previous translations have a little bug who causes misspronounce in the reply to dialog. This was fixed.
2022-02-25 07:50:08 -03:00
6147ca8658 Merge pull request #460 from nidza07/SerbianTranslation
Updated Serbian translation
2022-02-24 17:13:04 -06:00
Nikola Jovic
7833522b56 Updated Serbian translation 2022-02-25 00:01:32 +01:00
dbafeb9872 Fixed some typos 2022-02-24 16:29:59 -06:00
c6865a7742 Remove some platform independent code for a while 2022-02-24 16:26:05 -06:00
fcb2ce119b Sorted imports on main controller 2022-02-24 16:18:01 -06:00
9f74d568f0 Add attribute type to mastodon session 2022-02-24 16:08:29 -06:00
e3137f4c3d Merge branch 'unittests' into mastodon 2022-02-24 15:07:11 -06:00
3f58112a61 Finished session manager refactoring 2022-02-24 14:00:07 -06:00
307085b0d5 Merge branch 'next-gen' into mastodon 2022-02-24 13:36:46 -06:00
44ea77b605 Added more docs 2022-02-24 13:35:47 -06:00
5e47e30bc3 Merge pull request #459 from jonasmarques/next-gen
Updated Brazilian Portuguese Translation
2022-02-24 13:33:35 -06:00
jonasmarques
c6a2ba6a31 Updated Brazilian Portuguese Translation
New entries  to pt_BR  translated. Just recompile it to work  on compiled version.
2022-02-24 16:23:17 -03:00
085c9038b5 Removed old imports used for python 2 2022-02-24 12:43:06 -06:00
af4e72ee27 Refactored SessionManager so it will use pubsub as a communication pattern between GUI and logic and adds mastodon auth 2022-02-24 12:25:45 -06:00
9322241747 Remove more unneeded code 2022-02-24 10:36:16 -06:00
116a0288d4 Removed code for old issue reporting module 2022-02-24 10:34:11 -06:00
d0322e7131 Merge branch 'next-gen' into mastodon 2022-02-24 10:24:12 -06:00
000cf1aff1 Merged latest code 2022-02-24 08:55:02 -06:00
2f0515a449 prepared everything for new version 2022-02-23 15:19:49 -06:00
ac9efd7550 Merge pull request #458 from riku22/japanese_translation
Update Japanese translation
2022-02-15 17:48:59 -06:00
riku
540a99f02f Update Japanese translation 2022-02-16 08:03:27 +09:00
8e95843634 Updated to Tweepy V4.5.0 2022-02-15 15:59:35 -06:00
cf56b518d6 Update Twitter session to Tweepy V4.5.0 2022-02-15 15:56:08 -06:00
1262a9d784 Merge branch 'next-gen' into unittests 2022-01-27 09:11:33 -06:00
7c85ceced1 Merge pull request #456 from CoBC/fr_260122
Update french translations
2022-01-26 16:18:04 -06:00
Corentin Bacqué-Cazenave
3d452b3db8 Update french translations 2022-01-26 18:27:32 +01:00
950ece43d5 Merge pull request #455 from manuelcortez/handle_protected_account_interactions
Protected account retweet restrictions
2022-01-25 12:04:21 -06:00
ac0e7380b0 TWBlue should not allow users to retweet or quote any protected account. Closes #454 2022-01-25 12:01:03 -06:00
6e0a94355f Improvements to template substitutions. Closes #452 2022-01-25 10:42:39 -06:00
e43ddad678 Catch image description sent by Streaming API. Should be enough to fix #449 2022-01-25 01:27:52 -06:00
c048c3ff32 Retrieve usernames for timelines from the local database, as opposed to use the last API call as this might not contain items at times 2022-01-25 01:26:23 -06:00
301e3d4361 Display properly HTML Entities in tweets 2022-01-10 05:30:14 -06:00
7a78accd1f Fixed a typo 2022-01-10 05:06:31 -06:00
d7afa77c49 Changed params names to avoid confussions 2022-01-10 05:05:27 -06:00
e7a30b418a Merge branch 'next-gen' into unittests 2022-01-10 04:48:10 -06:00
a645e0b964 TWBlue should no longer load old items in buffer 2022-01-10 04:35:23 -06:00
e8287c75cc Merge branch 'change_author_information' into 'next-gen'
Change author information

See merge request twblue/twblue!2
2022-01-10 00:07:36 +00:00
6a839baed7 Change author information 2022-01-10 00:07:36 +00:00
8924f787d4 Added unittest for tweet with multiple mentions 2022-01-07 17:44:15 -06:00
b81aff7f8d Fixed syntax error on linux module from keyboard_handler 2022-01-07 17:20:21 -06:00
1dfe256cfe Updated tests for templates 2022-01-07 13:31:15 -06:00
ee8e4b1d8b Added unit for a couple methods on templates 2022-01-07 12:47:34 -06:00
0317eff6a5 Moved current tests from unittest to pytest 2022-01-07 11:41:24 -06:00
793bd2cf5b Added pytest and coverage as dependencies so we can ensure unittests pass later 2022-01-07 08:38:47 -06:00
José Manuel Delicado
c0ee1d2c29 Merge pull request #448 from riku22/japanese_translation
Update Japanese translation
2021-12-29 09:12:01 +01:00
riku
9e6740253c Update Japanese translation 2021-12-29 15:54:17 +09:00
c08eb499e1 Merge pull request #446 from CoBC/fr_271221
Some french fixes
2021-12-28 18:39:02 -06:00
Oreonan
5d0e1f38ab Some french fixes 2021-12-27 23:26:40 +01:00
1d60751dbd Merge pull request #445 from CoBC/fr_221221
Update french interface
2021-12-22 12:40:59 -06:00
Oreonan
b23915e546 Update french interface 2021-12-22 18:30:46 +01:00
c8da3bdfdb Fixed indentation error 2021-12-22 08:22:36 -06:00
ebf7916ae0 Merge pull request #444 from manuelcortez/error_saving_config
Fixed TWBlue asking for a restart due to old reference to the events …
2021-12-22 08:16:07 -06:00
33338ba09a Merge pull request #442 from manuelcortez/templates
Add Templates for invisible interface
2021-12-22 08:15:45 -06:00
8b50f3138c Merge pull request #359 from guredora403/configration_invalid
add: configration invalid error dialog
2021-12-22 08:15:20 -06:00
ae28c374d5 Merge pull request #440 from nidza07/Win11Keymap
Updated Windows 11 keymap
2021-12-22 08:14:44 -06:00
5a2786967b Merge branch 'next-gen' into configration_invalid 2021-12-21 15:58:30 -06:00
ed765117a5 Merge branch 'next-gen' into Win11Keymap 2021-12-21 15:45:06 -06:00
911e8d3cfd Fixed TWBlue asking for a restart due to old reference to the events buffer in settings. Fixes #413 2021-12-21 15:35:35 -06:00
b6ae9f4b79 Updated changelog 2021-12-21 15:10:12 -06:00
a74825a0f6 Add missing string to translation catalogs 2021-12-21 13:57:32 -06:00
445c33f003 Add default templates to translation catalog 2021-12-21 13:56:29 -06:00
81963dbb53 Updated sent direct messages template 2021-12-21 13:55:48 -06:00
b4526c12c9 Integrate template edition into account settings dialog 2021-12-21 13:21:58 -06:00
b2f9aef7f7 Added edit template controller 2021-12-21 12:11:12 -06:00
95063cd472 Added restore button for template edit dialog 2021-12-21 12:10:15 -06:00
4434a5b971 Added dialog for editing templates 2021-12-21 09:20:59 -06:00
2de9f8f9b3 added all variables available for template objects 2021-12-20 16:03:21 -06:00
a6ecd37547 Implement users template in Twitter buffers 2021-12-13 09:54:06 -06:00
03c330c0a4 Added default template for Twitter user objects 2021-12-13 09:53:44 -06:00
ab1a0946a4 Added rendering function for twitter user objects 2021-12-13 09:52:52 -06:00
1f253221b3 Merge branch 'next-gen' of github.com:manuelcortez/twblue into next-gen 2021-12-10 17:27:15 -06:00
58ba722bd7 Added templates for direct messages and sent direct messages 2021-12-10 17:15:24 -06:00
416151570c Request image description features for all created buffers by default 2021-12-10 15:23:41 -06:00
af4594f16c Render tweets for invisible interface from template specified in config 2021-12-10 15:22:42 -06:00
a47fa31346 Use session to retrieve users in templates, when applied to reduced tweets 2021-12-10 15:04:05 -06:00
40e13250ca Added a base template for tweets 2021-12-10 13:36:08 -06:00
0bd366c539 Added first draft to a new templating system which could be used in invisible interface for now 2021-12-10 13:32:46 -06:00
b67fc0ff38 Made some cleanup in unneeded imports 2021-12-10 09:53:49 -06:00
86a2eb7c0d Restored conversation and threads support powered by Twitter API V2 2021-12-09 10:46:07 -06:00
78c10b38e5 Fixed issue when sending tweets and replies with images 2021-12-08 12:49:20 -06:00
Nikola Jovic
cfd4fd12d3 Updated Windows 11 keymap 2021-11-17 19:35:02 +01:00
José Manuel Delicado Alcolea
806111c36e Included more dependencies in the setup script 2021-11-15 13:04:18 +01:00
7bfbadc254 Update write_version_data 2021-11-12 15:01:54 -06:00
3ccb3a5be5 Updated Spanish locale 2021-11-12 13:33:54 -06:00
José Manuel Delicado Alcolea
f264f3807f Updated Windows dependencies 2021-11-12 09:08:50 +01:00
3902a57d6b Merge pull request #437 from riku22/japanese_translation
Update Japanese translation
2021-11-11 17:48:16 -06:00
riku
485e5ecbd1 Merge branch 'next-gen' into japanese_translation 2021-11-12 08:26:14 +09:00
riku
f7a50d22e2 Update Japanese translation 2021-11-12 08:23:24 +09:00
43b1a834d1 Merge branch 'next-gen' of github.com:manuelcortez/twblue into next-gen 2021-11-11 15:14:38 -06:00
d6571a95cb Quote tweets properly according to Twitter's API V2 docs 2021-11-11 15:13:58 -06:00
4ba2753b79 Merge pull request #435 from nidza07/SerbianTranslation
Updated Serbian translation
2021-11-11 12:39:48 -06:00
6951541193 Merge pull request #434 from Oreonan/fr_111121
Update french interface
2021-11-11 12:39:27 -06:00
b329ac8e3e Improved a little bit text dialogs's size for sending tweets, replies and dm's 2021-11-11 12:33:38 -06:00
538d6137d0 Limit Poll options to 25 characters each 2021-11-11 08:37:07 -06:00
622b0e6128 Access correctly on_reply_to_tweet_id from the dict response returned by call to V2 API 2021-11-11 08:36:29 -06:00
Nikola Jovic
0e91ca3d4d Updated Serbian translation 2021-11-11 01:30:30 +01:00
Oreonan
8abcb3623d Update french interface 2021-11-11 01:09:19 +01:00
b3bf0ab8e6 Removed calls to SetMaxLength in dialogs 2021-11-10 17:35:24 -06:00
eea059b905 Merge pull request #433 from manuelcortez/new_tweet_dialogs
New tweet dialogs
2021-11-10 17:17:50 -06:00
e9f6fd529e Updated changelog 2021-11-10 16:32:39 -06:00
b0cfc5978c Updated reply dialog with some changes in add menu 2021-11-10 16:32:14 -06:00
77d13fdc28 Added support for posting polls 2021-11-10 15:14:57 -06:00
514e66411d Merge branch 'new_tweet_dialogs' of github.com:manuelcortez/twblue into new_tweet_dialogs 2021-11-10 12:36:02 -06:00
d9f4b86d91 Empty attachments after adding a new tweet 2021-11-10 12:35:43 -06:00
a6964a1bb9 Merge pull request #432 from Mohamed00/shortcut
Fixes
2021-11-10 12:30:08 -06:00
a43101e694 Reimplemented direct messages with support for media 2021-11-10 12:21:07 -06:00
Mohamed
9e7542f513 Removed url_shortener import 2021-11-10 13:01:24 -05:00
Mohamed
6346651edf Added a shortcut for the add new tweet button 2021-11-10 12:53:34 -05:00
1e2464c4fa Made Dm dialog to hide attachments panel when needed 2021-11-10 11:36:06 -06:00
dbecf341ec Stop using text_processor in tweet displayer 2021-11-10 11:24:50 -06:00
605868eff9 Added functions to make TWBlue respect Twitter limits when adding media items 2021-11-10 09:47:53 -06:00
8fed52118f Finished implementation of new tweet and reply calls in buffers 2021-11-09 13:46:36 -06:00
15d0f4c65e Restored some imports on dialogs 2021-11-09 13:34:49 -06:00
a2393fe3e9 Updated dialogs package 2021-11-08 17:20:16 -06:00
80adf381c9 Implemented new GUI in people and direct message buffers 2021-11-08 17:19:12 -06:00
269db95fe3 Implemented code to quote Tweets by using the new GUI 2021-11-08 16:44:03 -06:00
cfc25eb89a Implemented tweet, reply and direct message in base buffer 2021-11-08 16:14:45 -06:00
2b6efef831 Update code on autocompletion users module to use WX methods from controls in the new Tweet GUI'S 2021-11-08 16:13:59 -06:00
f0456af656 Fixed an issue when uploading Videos to Twitter 2021-11-08 16:12:47 -06:00
6d505c6fe7 Added new code for Tweet GUI and attachment of photos and gifts 2021-11-08 16:11:09 -06:00
38e3274adc Removed GUI for tweets/reply/dm/viewTweets items and attachment code 2021-11-08 16:09:32 -06:00
2c70fe46b7 Removed url_shortener from sound handling module 2021-11-08 15:30:40 -06:00
1c8ee1a64f Removed URL Shorteners 2021-11-08 15:29:23 -06:00
076761b9dd Merge branch 'next-gen' of gitlab.com:twblue/twblue into next-gen 2021-11-07 06:36:03 -06:00
556ffd832b Updated translation machine catalog for french translation 2021-11-07 06:34:27 -06:00
cedb290956 fixed an issue when deleting a buffer in a session where there were trending topics opened 2021-11-05 22:35:50 -06:00
66bf95ee62 Added reply function to session module 2021-11-05 13:10:45 -06:00
4f0db5537e Added function to send tweets and threads in session module so it will be used globally later 2021-11-05 11:49:51 -06:00
José Manuel Delicado
7c5c191deb Merge pull request #428 from riku22/japanese_translation
Update Japanese translation
2021-11-04 23:31:27 +01:00
riku
0cf0a64f40 Update Japanese translation 2021-11-05 07:15:33 +09:00
714d849884 Merge branch 'next-gen' of github.com:manuelcortez/twblue into next-gen 2021-11-04 11:17:25 -06:00
a80184bf20 Restored conversation support with API V1 as V2 hits the limits quickly. Closes #427 2021-11-04 11:17:07 -06:00
José Manuel Delicado
46fb00e609 Merge pull request #426 from Oreonan/fr_031121
Update french interface
2021-11-04 17:09:50 +01:00
Oreonan
4ddb406c8d Reduce texts 2021-11-04 17:00:59 +01:00
6b9540a0a8 Added a base mastodon buffer GUI 2021-11-03 13:16:39 -06:00
5687cf6a62 Move Twitter buffers to a specific package 2021-11-03 13:00:35 -06:00
1fd2b5914b Merge branch 'next-gen' into mastodon 2021-11-03 12:31:51 -06:00
924f5d8e9f Updated main controller file 2021-11-03 12:30:46 -06:00
13c441557b Updated manual 2021-11-03 12:30:06 -06:00
Oreonan
2c4ec7b1c0 Update french interface 2021-11-03 18:58:59 +01:00
c4b7c35c7f Updated changelog 2021-11-03 09:49:52 -06:00
2d46315de9 Removed old pyinstaller file 2021-11-03 09:31:23 -06:00
6904c153d4 Display error if user has not provided a name for a filter upon creation 2021-11-03 09:10:35 -06:00
8b06437cad Started to update documentation 2021-11-02 17:52:07 -06:00
c3261a4e2c Updated sintax for doc and changelog locales 2021-11-02 10:59:03 -06:00
9f7892ff03 Updated spanish translation for changelog 2021-11-02 10:11:24 -06:00
ab44ce6fcb Rebuilt documentation generators 2021-11-01 17:18:49 -06:00
ed80558273 Remove BOM from changelog 2021-11-01 17:04:03 -06:00
60a67947e6 Updated Pygettext to Python 3.7.9 2021-11-01 10:03:51 -06:00
8a8f1998ac Added usable appkeys for sources 2021-11-01 09:58:57 -06:00
cd415ba673 Merge pull request #422 from riku22/japanese_translation
Update Japanese translation
2021-11-01 05:48:03 -06:00
f9e58b5724 Updated Spanish Translation for app's interface 2021-11-01 05:46:44 -06:00
riku
94ca935b2f Updated Japanese translation 2021-11-01 20:37:39 +09:00
84fa2fad91 Fixed title for Trending topic buffers after a restart. Closes #421 2021-11-01 05:18:46 -06:00
ff0a2b5692 Retrieve all tweets from a thread properly. closes #417 2021-11-01 00:11:46 -06:00
b39b732a93 Updated Readme 2021-10-31 19:32:50 -06:00
b04a1c74a7 Fixed a bug when clearing direct messages buffer. Closes #418 2021-10-31 19:29:11 -06:00
ffb11b8226 Updated changelog 2021-10-31 19:27:59 -06:00
d863aafa8c Added mastodon.py to the list of dependencies 2021-08-27 15:47:04 -05:00
5bce84b786 Added default config template for Mastodon 2021-08-27 15:43:20 -05:00
9eab9ad5f0 Added Mastodon authorisation and authentication methods in a session. Added get_user_info, get_lists, get_muted_users 2021-08-27 15:42:34 -05:00
guredora
0e4b133858 add: configration invalid error dialog 2021-01-24 11:05:49 +09:00
269 changed files with 72650 additions and 75301 deletions

View File

@@ -1,6 +1,6 @@
variables:
GIT_SUBMODULE_STRATEGY: recursive
PYTHON: "C:\\python37\\python.exe"
PYTHON: "C:\\python310\\python.exe"
NSIS: "C:\\program files (x86)\\nsis\\makensis.exe"
stages:
@@ -17,9 +17,10 @@ twblue32:
- Set-Variable -Name "time" -Value (date -Format "%H:%m")
- echo ${time}
- echo "started by ${GITLAB_USER_NAME}"
- choco install python --version 3.7.9 -y -ForceX86
- choco install python --version 3.10.8 -y -ForceX86
- '&$env:PYTHON -V'
- '&$env:PYTHON -m pip install --upgrade pip'
- '&$env:PYTHON -m pip install --upgrade https://github.com/josephsl/wxpy32whl/blob/main/wxPython-4.2.0-cp310-cp310-win32.whl?raw=true'
- '&$env:PYTHON -m pip install --upgrade -r requirements.txt'
stage: build
interruptible: true
@@ -30,6 +31,7 @@ twblue32:
- cd ..\src
- '&$env:PYTHON ..\doc\generator.py'
- '&$env:PYTHON write_version_data.py'
- New-Item "appkeys.py" -ItemType File -Value "twitter_api_key='$TWITTER_API_KEY'`ntwitter_api_secret='$TWITTER_API_SECRET'"
- '&$env:PYTHON setup.py build'
- cd ..
- mkdir artifacts
@@ -56,7 +58,7 @@ twblue64:
- Set-Variable -Name "time" -Value (date -Format "%H:%m")
- echo ${time}
- echo "started by ${GITLAB_USER_NAME}"
- choco install python --version 3.7.9 -y
- choco install python --version 3.10.8 -y
- '&$env:PYTHON -V'
- '&$env:PYTHON -m pip install --upgrade pip'
- '&$env:PYTHON -m pip install --upgrade -r requirements.txt'
@@ -69,6 +71,7 @@ twblue64:
- cd ..\src
- '&$env:PYTHON ..\doc\generator.py'
- '&$env:PYTHON write_version_data.py'
- New-Item "appkeys.py" -ItemType File -Value "twitter_api_key='$TWITTER_API_KEY'`ntwitter_api_secret='$TWITTER_API_SECRET'"
- '&$env:PYTHON setup.py build'
- cd ..
- mkdir artifacts

View File

@@ -21,6 +21,15 @@ See [TWBlue's webpage](http://twblue.es) for more details.
This document describes how to run tw blue from source and how to build a binary version which doesn't need Python and the other dependencies to run.
### Generating application keys
In order to communicate with Twitter, you will need to generate a set of API keys in their [developer portal](https://developer.twitter.com/en/portal/dashboard) (If you haven't signed up, [visit this site to register as a developer](https://developer.twitter.com/en/docs/twitter-api/getting-started/getting-access-to-the-twitter-api)) and create a module called appkeys.py, within the src directory, with the following content, replacing the example values with your set of API keys:
```
twitter_api_key='xxxxxxxxxx'
twitter_api_secret='xxxxxxxxxx'
```
### Required dependencies.
Although most dependencies can be found in the windows-dependencies directory, we provide links to their official websites. If you are cloning with git, don't forget to initialize and update the submodules to get the windows-dependencies folder. You can use these two commands to perform this task from git bash:
@@ -31,18 +40,22 @@ Although most dependencies can be found in the windows-dependencies directory, w
#### Dependencies packaged in windows installers
* [Python,](https://python.org) version 3.8.7
If you want to build both x86 and x64 binaries, you can install python x86 to C:\python38 and python x64 to C:\python38x64, for example.
* [Python,](https://python.org) version 3.10.8
If you want to build both x86 and x64 binaries, you can install python x64 to C:\python310 and python x86 to C:\python310-32, for example.
#### Dependencies that must be installed using pip
Python installs a tool called Pip that allows to install packages in a simple way. You can find it in the python scripts directory. To install packages using Pip, you have to navigate to the scripts directory using a command prompt, for example:
`cd C:\python37x64\scripts`
`cd C:\python310\scripts`
You can also add the scripts folder to your path environment variable or choose the corresponding option when installing Python.
Note: pip and setuptools are included in the Python installer since version 2.7.9.
Note: If you are using Python for 32-bit systems, you will need to install WXPython for 32-bits before running the command for installing everything else. You can do so by running the following command:
`pip install --upgrade https://github.com/josephsl/wxpy32whl/blob/main/wxPython-4.2.0-cp310-cp310-win32.whl?raw=true`
Pip is able to install packages listed in a special text file, called the requirements file. To install all remaining dependencies, perform the following command:
`pip install -r requirements.txt`

View File

@@ -39,5 +39,5 @@ florian Ionașcu
Christian Leo Mameli
Natalia Hedlund (Наталья Хедлунд)
Valeria (Валерия)
Oreonan
Corentin Bacqué-Cazenave
Artem Plaksin (maniyax)

View File

@@ -1,7 +1,93 @@
TWBlue Changelog
TWBlue Changelog
## changes in this version
Most of all changes in this release are focused on adding Mastodon support to TWBlue. The features present to handle Twitter should not have been altered in any way. We were not intended to release this version so soon, but unfortunately, Twitter started to present issues in some regions with one particular API endpoint we were using, making impossible for everyone in such regions to use the application. We will release more updates to fix any possible issue regarding Twitter API, but please take into account that this is sometimes an issue happening in Twitter's servers and while we do our best to make TWBlue work despite those problems, you might encounter glitches from time to time.
* TWBlue now builds with Python 3.10.8. ([#493](https://github.com/MCV-Software/TWBlue/issues/493))
* This change also drops support for Windows 7.
* The TWBlue interface has not been translated yet, as we are releasing this update to fix an important Twitter issue for some regions.
* Twitter sessions should be able to be opened properly again in TWBlue, in regions where it didn't work since last week.
* It is now possible to log in to instances of mastodon, hometown and similar software (Pleroma should work as well, although it has not been tested at this time). From the session manager, clicking on the “new account” button will bring up a menu from which you can select whether you want to log in to Twitter or Mastodon. For instances that have a different character limit than the one set by Mastodon, TWBlue will detect the new limit and adjust the dialogs to allow you to use it correctly.
* Most of the TWBlue GUI has been adapted so that the buffers reflect the change of social network (in mastodon, for example, the buttons to write posts say post instead of tweet). However, the menu bar has not yet been updated. This means that most of the options still refer to Twitter, although they can be used with mastodon accounts. For example, if you select the “tweet” menu in the menu bar, and then select the “Retweet” option, TWBlue will actually do a “boost” if the buffer you are in is a Mastodon account buffer.
* Keystrokes for the invisible interface also refer to terms used in Twitter, but can be applied to Mastodon as well.
* There are some features, within TWBlue, that are not yet compatible with mastodon accounts. These are as follows:
* User autocompletion.
* Currently, it is not possible to update account settings for mastodon sessions. However, if you know how to edit configuration files, you can close TWBlue, change your session file with any text editor and restart the application to update what you want.
* The template editor is not yet available for mastodon accounts.
* Filters have not yet been implemented in TWBlue mastodon support.
* User aliases are not implemented yet.
* It is not possible to view a users profile, nor edit your own, for now. However, you can use the keystroke to open the item in the browser when focusing a user to access their profile website. This only works in buffers where users are listed.
* You cannot manage lists in TWBlue at the moment.
* Most of the buffers planned for mastodon should just work. Among those currently tested are: home (main timeline for the logged-in user), Local (public posts for the instance), federated (public posts for all federating instances), mentions, direct messages, sent posts, favorites, bookmarks, followers, following, blocked users, muted users, user searches and timelines for users.
* The difference between favorites and bookmarks is that the author of the post can see who has marked his posts as favorites, but bookmarks are completely private. In any buffer containing mastodon posts, except direct messages, the GUI will display an option to add the post to favorites or bookmarks.
* Direct messages in mastodon are posts, exactly like normal posts, but with their privacy setting set so that they can only be seen by the accounts that are mentioned. In the direct message buffer, a conversation will appear for each item in the buffer. The conversation represents a thread of messages, but TWBlue can only display the last of the messages sent. This is similar to what happens on platforms like Telegram, where you can only see the list of conversations at the beginning. To see the entire thread of direct messages present in a conversation, you can use the command to open the conversation, or go to the “tweet” menu in the menu bar, and then towards the “view conversation” option. This will create a new conversation buffer that will be located just after the direct messages buffer (for the GUI, the buffer will be located just inside the direct messages buffer in the buffer tree). When a private post appears (whose visibility only allows the mentioned accounts to see it), TWBlue will display that post in the home buffer, in mentions and also will update/create the conversation with that item. This is because Mastodon does not differentiate between a private message and a normal post. You can reply to the post in any buffer to continue the conversation. If you reply to any post, the privacy set in the original post is maintained by default, but can also be changed.
* The buffer showing the federated timeline has been disabled from settings. This is because on servers that federate with many instances it can load many posts in a very short time. To enable this buffer, for now, edit the TWBlue configuration while the application is closed, and add the “federated” buffer in the option called “buffer_order”. As soon as buffers can be shown or hidden, this process can be done through the GUI.
* There is a Streaming API that allows the elements for the start buffers, mentions, direct messages, sent posts and followers to appear in real time. This feature is implemented by default and should also just work.
* Timelines for users only allow to get all posts from users who are in the same instance. For users belonging to other instances, you can get the posts that have been downloaded to your instance since your instance “knows” the remote user.
* Timelines for followers and following can be fully retrieved only for users belonging to the same instance. Remote users may yield unclear results.
* You can search by users (by opening a search and selecting the “users” radio button). The search can be done by local users, such as twblue, or by remote users, such as @twblue@maaw.social.
* In all buffers, a maximum of 40 items are retrieved per load, but more can be retrieved by using the option to load more items in the buffer.
* In post buffers, you can do most of the actions already supported in TWBlue (boost, add/remove from favorites or bookmarks, reply, send message to user, open post URL, play audio or video, open post on web, view conversation, open action dialog for user).
* In user buffers, you can send private message to the user, and open user actions dialog, which in turn allows you to follow/unfollow, block/unblock and mute/unmute.
* When writing posts, it is possible to attach up to 4 images, 4 givs, or even a video, poll, or audio. It is also possible to add the “sensitive content” tag to posts, change privacy and write a content warning text. It is possible to create threads using the “add post” button.
* When replying to a post, TWBlue will place the username of all participants in the item you reply to. The privacy options will default to those of the original post.
## Changes in version 2022.8.28
* the user autocompletion feature has been completely rewritten to be easier to use, particularly for people with many followers/following users:
* In the account settings dialog, there's a button that opens up a new dialog that allows you to "scan" your account in order to add all users from your followers/following list. This process will read your data directly from Twitter and depending in the amount of people you have in your account it might take too many API calls. Please use it with caution. You can, for example, do the process separately for your followers/following people so it will be easier to handle, in case you have a massive amount of people. If TWBlue is unable to complete the scan, you will see an error and will be prompted to try again in 15 minutes, once your API calls have refreshed.
* It is possible to use the user autocompletion functionality in dialogs where you can select an user, for example when adding or removing someone from a list, or displaying lists for someone.
* Implemented a new setting, available in the account settings dialog, that allows to hide emojis in twitter usernames.
* TWBlue should be able to sort conversations in a more logical way. This should make it easier to follow a long thread in Twitter.
* When opening a thread, TWBlue should be able to load the right conversation if the original tweet from where the thread was loaded was a retweet.
* TWBlue will restart the Streaming subsystem every time there are changes to followed, muted or blocked users within the application.
* Fixed error when attempting to mention an user by using the "mention" button in any people buffer. Now tweets should be posted normally.
* Fixed error when loading other user lists. ([#465](https://github.com/MCV-Software/TWBlue/issues/465))
* Fixed an issue that was making TWBlue to display incorrectly some retweets of quoted tweets.
* If TWBlue is unable to open a timeline for someone who has blocked you, this will be reported in a dialog. ([#485,](https://github.com/mcv-software/twblue/issues/485))
* Added "find a string in the currently focused buffer" action into Windows 10 and windows 11 keymap. ([#476](https://github.com/MCV-Software/TWBlue/pull/476))
## changes in version 22.2.23
* We have added Experimental support for templates in the invisible interface. The GUI will remain unchanged for now:
* Each object (tweet, received direct message, sent direct message and people) has its own template in the settings. You can edit those templates from the account settings dialog, in the new "templates" tab.
* Every template is composed of the group of variables you want to display for each object. Each variable will start with a dollar sign ($) and cannot contain spaces or special characters. Templates can include arbitrary text that will not be processed. When editing the example templates, you can get an idea of the variables that are available for each object by using the template editing dialog. When you press enter on a variable from the list of available variables, it will be added to the template automatically. When you try to save a template, TWBlue will warn you if the template is incorrectly formatted or if it includes variables that do not exist in the information provided by objects. It is also possible to return to default values from the same dialog when editing a template.
* TWBlue can display image descriptions within Tweet templates. For that, you can use the $image_description variable in your template.
* We have restored conversation and threads support powered by Twitter API V2 thanks to a set of improvements we have done in the application, as well as more generous limits to Tweet monthly cap by Twitter.
* In the Windows 11 Keymap, the default shortcut to open the keystrokes editor is now CTRL+Alt+Windows+K to avoid conflicts with the new global mute microphone shortcut.
* TWBlue show display properly HTML entities in tweet's text.
* TWBlue should no longer load old tweets in buffers.
* Fixed issue when uploading attachments (images, videos or gif files) while sending tweets or replies.
* Fixed an error that was making TWBlue to ask for a restart after saving account settings, even if such restart was not required. ([#413,](https://github.com/manuelcortez/TWBlue/issues/413))
## Changes in version 2021.11.12
* Now it is possible to create a tweet from a trending topics buffer again.
* TWBlue now includes a completely new set of dialogs to handle tweeting, replying and sending direct messages that takes advantage of more Twitter features.
* It is possible to add videos in tweets and direct messages by using the new "add" button, located in every dialog where media can be added. Twitter suggests to add videos from 5 seconds up to 2 minutes lenght, in mp4 format (video Codec H.264 and audio codec AAC). Currently, TWBlue does not check if the uploaded video complies with Twitter media requirements. You can add only a video in a tweet or direct message. No other kind of media can be added after a video is in a tweet. If the video was unable to be uploaded successfully, the tweet or direct message won't be created.
* Now you can add a poll to tweets. Polls can have up to 4 different options and allow voting up to 7 days after being created. Take into account, though, that currently TWBlue does not support reading polls in tweets.
* TWBlue now support threads while creating a new tweet. There is a new button, called add tweet which will add the current tweet to the thread and will allow you to write another tweet in the thread. Every tweet might include media (up to 4 photos, or one GIF image or a video) or up to one poll.
* Some functionality was removed from tweet dialogs within TWBlue. Particularly, URL shorteners and long tweets via Twishort. You still can read long tweets posted via Twishort, though.
## Changes in version 2021.11.07
* TWBlue should retrieve tweets from threads and conversations in a more reliable way. Tweets in the same thread (made by the same author) will be sorted correctly, although replies to the thread (made by different people) may not be ordered in the same way they are displayed in Twitter apps. ([#417](https://github.com/manuelcortez/TWBlue/issues/417))
* When creating a filter, TWBlue will show an error if user has not provided a name for the filter. Before, unnamed filters were a cause of config breaks in the application.
* It is again possible to read the changelog for TWBlue from the help menu in the menu bar.
* fixed a bug when clearing the direct messages buffer. ([#418](https://github.com/manuelcortez/TWBlue/issues/418))
* fixed an issue that was making TWBlue to show incorrectly titles for trending topic buffers upon startup. ([#421](https://github.com/manuelcortez/TWBlue/issues/421))
* fixed an issue that was making users of the graphical user interface to delete a buffer if a trends buffer was opened in the same session.
* Updated Spanish, Japanese and french translations.
## Changes in Version 2021.10.30
* Fixed many errors in the way we compile TWBlue, so users of 64 bits systems and particularly windows 7 users would be able to install TWBlue again. In case of issues with versions prior to 2021.10.30, please remove everything related to TWBlue (except configs) and reinstall the version 2021.10.30 to fix any possible error. This step won't be needed again in 23 months. ([#416,](https://github.com/manuelcortez/TWBlue/issues/416), [#415,](https://github.com/manuelcortez/TWBlue/issues/415))
* fixed an issue that was making impossible to manually add an user to the autocomplete users database.
* Started to improve support to conversations by searching for conversation_id.
## changes in version 2021.10.27
* Added an user alias manager, located in the application menu in the menu bar. From this dialog, it is possible to review, add, edit or remove user aliases for the current account. ([#401](https://github.com/manuelcortez/TWBlue/issues/401))
* TWBlue now closes the VLC player window automatically when a video reaches its end. ([#399](https://github.com/manuelcortez/TWBlue/issues/399))
* After a lot of time, TWBlue now uses a new default Soundpack, called FreakyBlue. This soundpack will be set by default in all new sessions created in the application. Thanks to [Andre Louis](https://twitter.com/FreakyFwoof) for the pack. ([#247](https://github.com/manuelcortez/TWBlue/issues/247))
@@ -239,4 +325,4 @@
* New followers and friends buffer for user timelines.
---
Copyright © 2014-2017, Manuel Cortez.
Copyright © 2014-2021, Manuel Cortez.

View File

@@ -1,5 +1,4 @@
# -*- coding: utf-8 -*-
from codecs import open
""" This script converts the hold documentation (saved in markdown files) in a python file with a list of strings to translate it using gettext."""
def prepare_documentation_in_file(fileSource, fileDest):
@@ -14,11 +13,11 @@ def prepare_documentation_in_file(fileSource, fileDest):
f2.write("documentation = [\n")
for i in lns:
if "\n" == i:
newvar = "\"\","
newvar = "\"\",\n"
elif "\n" == i[-1]:
newvar = "\"\"\"%s\"\"\",\n" % (i[:-1])
newvar = "_(\"\"\"%s\"\"\"),\n" % (i[:-1])
else:
newvar = "\"\"\"%s\"\"\",\n" % (i)
newvar = "_(\"\"\"%s\"\"\"),\n" % (i)
f2.write(newvar)
f1.close()
f2.write("]")

View File

@@ -5,30 +5,48 @@ import locale
import paths
import markdown
import shutil
from codecs import open as _open
from importlib import reload
def get_translation_function(name, language):
if language == "en":
return gettext.NullTranslations()
translation_function = gettext.translation(name, os.path.join(paths.app_path(), "locales"), languages=[language])
return translation_function
# Languages already translated or translating the documentation.
documentation_languages = ["en", "es", "fr", "de", "it", "gl", "ja", "ru", "ro", "eu", "ca", "da", "sr"]
# the list of supported language codes of TW Blue
languages = ["en", "es", "fr", "de", "it", "gl", "ja", "ru", "ro", "eu", "ca", "da", "sr"]
def generate_document(language, document_type="documentation"):
# Changelog translated languages.
changelog_languages = ["en", "ca", "de", "es", "eu", "fr", "gl", "ja", "ro", "ru", "sr"]
# this function will help us to have both strings.py and changelog.py without issues by installing a global dummy translation function.
def install_null_translation(name):
_ = gettext.NullTranslations()
_.install()
return
def get_translations(name):
""" Create translation instances for every language of the translated document. """
translations = {}
if "documentation" in name:
langs = documentation_languages
else:
langs = changelog_languages
for l in langs:
if l != "en":
_ = gettext.translation(name, os.path.join(paths.app_path(), "locales"), languages=[l])
translations[l] = _
else:
_ = gettext.NullTranslations()
translations[l] = _
return translations
def generate_document(lang, lang_name, document_type="documentation"):
""" Generates a document by using the provided lang object, which should be a translation, and lang_name, which should be the two letter code representing the language. """
if document_type == "documentation":
translation_file = "twblue-documentation"
translation_function = get_translation_function(translation_file, language)
markdown_file = markdown.markdown("\n".join([translation_function.gettext(s[:-1]) if s != "\n" else s for s in strings.documentation[1:]]), extensions=["markdown.extensions.toc"])
title = translation_function.gettext(strings.documentation[0][:-1])
markdown_file = markdown.markdown("\n".join([lang.gettext(s) if s != "" else s for s in strings.documentation[1:]]), extensions=["markdown.extensions.toc"])
title = lang.gettext(strings.documentation[0])
filename = "manual.html"
elif document_type == "changelog":
translation_file = "twblue-changelog"
translation_function = get_translation_function(translation_file, language)
markdown_file = markdown.markdown("\n".join([translation_function.gettext(s[:-1]) if s != "\n" else s for s in changelog.documentation[1:]]), extensions=["markdown.extensions.toc"])
title = translation_function.gettext(changelog.documentation[0][:-1])
markdown_file = markdown.markdown("\n".join([lang.gettext(s) if s != "" else s for s in changelog.documentation[1:]]), extensions=["markdown.extensions.toc"])
title = lang.gettext(changelog.documentation[0])
filename = "changelog.html"
first_html_block = """<!doctype html>
<html lang="%s">
@@ -38,30 +56,32 @@ def generate_document(language, document_type="documentation"):
</head>
<body>
<header><h1>%s</h1></header>
""" % (language, title, title)
""" % (lang_name, title, title)
first_html_block = first_html_block+ markdown_file
first_html_block = first_html_block + "\n</body>\n</html>"
if not os.path.exists(os.path.join("documentation", language)):
os.mkdir(os.path.join("documentation", language))
mdfile = _open(os.path.join("documentation", language, filename), "w", encoding="utf-8")
if not os.path.exists(os.path.join("documentation", lang_name)):
os.mkdir(os.path.join("documentation", lang_name))
mdfile = open(os.path.join("documentation", lang_name, filename), "w", encoding="utf-8")
mdfile.write(first_html_block)
mdfile.close()
def create_documentation():
changelog_translations = get_translations("twblue-changelog")
documentation_translations = get_translations("twblue-documentation")
print("Creating documentation in the supported languages...\n")
if not os.path.exists("documentation"):
os.mkdir("documentation")
if os.path.exists(os.path.join("documentation", "license.txt")) == False:
shutil.copy(os.path.join("..", "license.txt"), os.path.join("documentation", "license.txt"))
for i in languages:
for i in documentation_languages:
print("Creating documentation for: %s" % (i,))
try:
generate_document(i)
generate_document(i, "changelog")
except:
continue
generate_document(lang_name=i, lang=documentation_translations.get(i))
for i in changelog_languages:
print("Creating changelog for: %s" % (i,))
generate_document(lang_name=i, lang=changelog_translations.get(i), document_type="changelog")
print("Done")
install_null_translation("twblue-documentation")
import strings
import changelog
create_documentation()

View File

@@ -5,7 +5,7 @@
msgid ""
msgstr ""
"Project-Id-Version: \n"
"POT-Creation-Date: 2019-03-17 13:34+Hora estndar romance\n"
"POT-Creation-Date: 2019-03-17 13:34\n"
"PO-Revision-Date: 2018-08-07 13:48-0500\n"
"Last-Translator: Manuel Cortez <manuel@manuelcortez.net>\n"
"Language-Team: \n"

View File

@@ -5,7 +5,7 @@
msgid ""
msgstr ""
"Project-Id-Version: TW Blue documentation 0.46\n"
"POT-Creation-Date: 2019-03-17 13:34+Hora estndar romance\n"
"POT-Creation-Date: 2019-03-17 13:34\n"
"PO-Revision-Date: 2015-11-27 08:32-0600\n"
"Last-Translator: Manuel Cortéz <manuel@manuelcortez.net>\n"
"Language-Team: Mohammed Al Shara <mohammed@atexplorer.com>\n"

View File

@@ -5,7 +5,7 @@
msgid ""
msgstr ""
"Project-Id-Version: TWBlue-Changelog V0.93\n"
"POT-Creation-Date: 2019-03-17 13:34+Hora estndar romance\n"
"POT-Creation-Date: 2019-03-17 13:34\n"
"PO-Revision-Date: 2018-08-08 11:46+0200\n"
"Last-Translator: Manuel Cortez <manuel@manuelcortez.net>\n"
"Language-Team: Fran Torres Gallego. <frantorresgallego@gmail.com>\n"

View File

@@ -5,7 +5,7 @@
msgid ""
msgstr ""
"Project-Id-Version: TW Blue documentation 0.89\n"
"POT-Creation-Date: 2019-03-17 13:34+Hora estndar romance\n"
"POT-Creation-Date: 2019-03-17 13:34\n"
"PO-Revision-Date: 2017-03-25 15:15+0100\n"
"Last-Translator: Joan Rabat <joanrabat@hotmail.com>\n"
"Language-Team: Francisco Torres Gallego <frantorresgallego@gmail.com>\n"

View File

@@ -5,7 +5,7 @@
msgid ""
msgstr ""
"Project-Id-Version: \n"
"POT-Creation-Date: 2019-03-17 13:34+Hora estndar romance\n"
"POT-Creation-Date: 2019-03-17 13:34\n"
"PO-Revision-Date: 2018-11-17 10:25+0100\n"
"Last-Translator: Nicolai Svendsen <chojiro1990@gmail.com>\n"
"Language-Team: \n"

Binary file not shown.

View File

@@ -5,7 +5,7 @@
msgid ""
msgstr ""
"Project-Id-Version: \n"
"POT-Creation-Date: 2019-03-17 13:34+Hora estndar romance\n"
"POT-Creation-Date: 2019-03-17 13:34\n"
"PO-Revision-Date: 2019-03-17 16:39+0100\n"
"Last-Translator: Steffen Schultz <steffenschultz@mailbox.org>\n"
"Language-Team: \n"

Binary file not shown.

View File

@@ -5,7 +5,7 @@
msgid ""
msgstr ""
"Project-Id-Version: TWBlue Documentation\n"
"POT-Creation-Date: 2019-03-17 13:34+Hora estndar romance\n"
"POT-Creation-Date: 2019-03-17 13:34\n"
"PO-Revision-Date: 2018-08-08 11:01+0200\n"
"Last-Translator: Steffen Schultz <schulle3o@yahoo.de>\n"
"Language-Team: Steffen Schultz <schulle3o@yahoo.de>\n"

File diff suppressed because it is too large Load Diff

View File

@@ -5,7 +5,7 @@
msgid ""
msgstr ""
"Project-Id-Version: twblue-documentation 0.84\n"
"POT-Creation-Date: 2019-03-17 13:34+Hora estndar romance\n"
"POT-Creation-Date: 2019-03-17 13:34\n"
"PO-Revision-Date: 2019-05-06 23:06+0200\n"
"Last-Translator: José Manuel Delicado <jmdaweb@hotmail.com>\n"
"Language-Team: Spanish <manuel@manuelcortez.net>\n"

View File

@@ -5,7 +5,7 @@
msgid ""
msgstr ""
"Project-Id-Version: \n"
"POT-Creation-Date: 2019-03-17 13:34+Hora estndar romance\n"
"POT-Creation-Date: 2019-03-17 13:34\n"
"PO-Revision-Date: 2018-08-07 13:51-0500\n"
"Last-Translator: Manuel Cortez <manuel@manuelcortez.net>\n"
"Language-Team: \n"

View File

@@ -1,635 +0,0 @@
# SOME DESCRIPTIVE TITLE.
# Copyright (C) YEAR ORGANIZATION
# FIRST AUTHOR <EMAIL@ADDRESS>, YEAR.
#
msgid ""
msgstr ""
"Project-Id-Version: \n"
"POT-Creation-Date: 2017-07-08 16:25+Hora de verano central (Mxico)\n"
"PO-Revision-Date: 2017-07-15 19:44+0200\n"
"Last-Translator: Sukil Etxenike <sukiletxe@yahoo.es>\n"
"Language-Team: \n"
"Language: eu\n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"
"Generated-By: pygettext.py 1.5\n"
"X-Generator: Poedit 2.0.1\n"
"Plural-Forms: nplurals=2; plural=(n != 1);\n"
#: ../doc/changelog.py:3
msgid "TWBlue Changelog"
msgstr "TwBlueren aldaketak"
#: ../doc/changelog.py:4
msgid "## changes in this version"
msgstr "## Aldaketak bertsio honetan"
#: ../doc/changelog.py:5
msgid ""
"* TWBlue will show an error when trying to open a timeline for a suspended "
"user. ([#128](https://github.com/manuelcortez/TWBlue/issues/128))"
msgstr ""
"* TWBluek errore bat erakutsiko du ezabatutako erabiltzaile batn denbora "
"lerro bat irekitzen saiatzean . ([#128](https://github.com/manuelcortez/"
"TWBlue/issues/128))"
#: ../doc/changelog.py:6
msgid ""
"* Removed TwUp as service as it no longer exists. ([#112](https://github.com/"
"manuelcortez/TWBlue/issues/112))"
msgstr ""
"* TwUp zerbitzua kendu da, jada ez delako existitzen. ([#112](https://github."
"com/manuelcortez/TWBlue/issues/112)) "
#: ../doc/changelog.py:7
msgid ""
"* Release audio files after uploading them. ([#130](https://github.com/"
"manuelcortez/TWBlue/issues/130))"
msgstr ""
"* Orain audio fitxategiak askatzen dira igo ondoren. ([#130](https://github."
"com/manuelcortez/TWBlue/issues/130))"
#: ../doc/changelog.py:8
msgid ""
"* Now TWBlue will use Yandex's translation services instead microsoft "
"translator. ([#132](https://github.com/manuelcortez/TWBlue/issues/132))"
msgstr ""
"* Orain TWBluek Yandexen itzultzailea erabiltzen du Microsoften "
"itzultzailearen ordez. ([#132](https://github.com/manuelcortez/TWBlue/"
"issues/132))"
#: ../doc/changelog.py:9
msgid ""
"* SndUp users will be able to upload audio in their account by using their "
"API Key again. ([#134](https://github.com/manuelcortez/TWBlue/issues/134))"
msgstr ""
"* SndUp-en erabiltzaileek orain audioak igo ditzakete haien API kodea "
"erabilita. ([#134](https://github.com/manuelcortez/TWBlue/issues/134))"
#: ../doc/changelog.py:10
msgid ""
"* old tweets shouldn't be added as new items in buffers. ([#116,](https://"
"github.com/manuelcortez/TWBlue/issues/116)) ([#133](https://github.com/"
"manuelcortez/TWBlue/issues/133))"
msgstr ""
"* Txio zaharrak ez lirateke buferretan elementu berri gisa agertu behar. "
"([#116,](https://github.com/manuelcortez/TWBlue/issues/116)) ([#133](https://"
"github.com/manuelcortez/TWBlue/issues/133))"
#: ../doc/changelog.py:11
msgid ""
"* All mentionned users should be displayed correctly in Twishort's long "
"tweets. ([#116,](https://github.com/manuelcortez/TWBlue/issues/116)) ([#135]"
"(https://github.com/manuelcortez/TWBlue/issues/135))"
msgstr ""
"* Aipatutako erabiltzaile guztiak ondo agertu beharko lirateke Tuishort-en "
"txio luzeetan. ([#116,](https://github.com/manuelcortez/TWBlue/issues/116)) "
"([#135](https://github.com/manuelcortez/TWBlue/issues/135))"
#: ../doc/changelog.py:12
msgid ""
"* It is possible to select a language for OCR service from the extras panel, "
"in the account settings dialogue. You can, however, set this to detect "
"automatically. OCR should work better in languages with special characters "
"or non-english symbols. ([#107](https://github.com/manuelcortez/TWBlue/"
"issues/107))"
msgstr ""
#: ../doc/changelog.py:13
msgid ""
"* Fixed a problem with JAWS for Windows and TWBlue. Now JAWS will work "
"normally in this update. [#100](https://github.com/manuelcortez/twblue/"
"issues/100)"
msgstr ""
#: ../doc/changelog.py:14
msgid "* And more ([#136,](https://github.com/manuelcortez/TWBlue/issues/136))"
msgstr ""
#: ../doc/changelog.py:15
msgid "## Changes in version 0.90"
msgstr ""
#: ../doc/changelog.py:16
msgid ""
"* Fixed a bug in long tweet parsing that was making TWBlue to disconnect the "
"streaming API. ([#103](https://github.com/manuelcortez/TWBlue/issues/103))"
msgstr ""
#: ../doc/changelog.py:17
msgid ""
"* Now OCR will work in images from retweets. It fixes a bug where TWBlue was "
"detecting images but couldn't apply OCR on them. ([#105](https://github.com/"
"manuelcortez/TWBlue/issues/105))"
msgstr ""
#: ../doc/changelog.py:18
msgid ""
"* TWBlue won't try to load tweets already deleted, made with Twishort. "
"Before, if someone posted a long tweet but deleted it in the Twishort's "
"site, TWBlue was trying to load the tweet and it was causing problems in all "
"the client. ([#113](https://github.com/manuelcortez/TWBlue/issues/113))"
msgstr ""
#: ../doc/changelog.py:19
msgid ""
"* TWBlue shows an error message when you try to view the profile of an user "
"that does not exist or has been suspended. ([#114,](https://github.com/"
"manuelcortez/TWBlue/issues/114) [#115](https://github.com/manuelcortez/"
"TWBlue/issues/115))"
msgstr ""
#: ../doc/changelog.py:20
msgid ""
"* The spellchecker module should select the right language when is set to "
"\"user default\". ([#117](https://github.com/manuelcortez/TWBlue/issues/117))"
msgstr ""
#: ../doc/changelog.py:21
msgid ""
"* Image description will be displayed in retweets too. ([#119](https://"
"github.com/manuelcortez/TWBlue/issues/119))"
msgstr ""
#: ../doc/changelog.py:22
msgid ""
"* When reading a long tweet, you shouldn't read strange entities anymore. "
"([#118](https://github.com/manuelcortez/twblue/issues/118))"
msgstr ""
#: ../doc/changelog.py:23
msgid ""
"* TWBlue will not try to load timelines if the user is blocking you. ([#125]"
"(https://github.com/manuelcortez/twblue/issues/125))"
msgstr ""
#: ../doc/changelog.py:24
msgid "## Changes in version 0.88 and 0.89"
msgstr ""
#: ../doc/changelog.py:25
msgid "* Fixed more issues with streams and reconnections."
msgstr ""
#: ../doc/changelog.py:26
msgid "* newer updates will indicate the release date in the updater."
msgstr ""
#: ../doc/changelog.py:27
msgid ""
"* Changes to keystrokes are reflected in keystroke editor automatically."
msgstr ""
#: ../doc/changelog.py:28
msgid ""
"* In replies with multiple users, if the mention to all checkbox is "
"unchecked, you will see a checkbox per user so you will be able to control "
"who will be mentioned in the reply."
msgstr ""
#: ../doc/changelog.py:29
msgid ""
"* Fixed a bug that caused duplicated user mentions in replies when the tweet "
"was made with Twishort."
msgstr ""
#: ../doc/changelog.py:30
msgid ""
"* Retweets should be displayed normally again when the originating tweet is "
"a Twishort's long tweet."
msgstr ""
#: ../doc/changelog.py:31
msgid ""
"* Changed the way TWBlue saves user timelines in configuration. Now it uses "
"user IDS instead usernames. With user IDS, if an user changes the username, "
"TWBlue still will create his/her timeline. This was not possible by using "
"usernames."
msgstr ""
#: ../doc/changelog.py:32
msgid ""
"* Added a new setting in the account settings dialogue that makes TWBlue to "
"show twitter usernames instead the full name."
msgstr ""
#: ../doc/changelog.py:33
msgid ""
"* Added OCR in twitter pictures. There is a new item in the tweet menu that "
"allows you to extract and display text in images. Also the keystroke alt+Win"
"+o has been added for the same purpose from the invisible interface."
msgstr ""
#: ../doc/changelog.py:34
msgid "* Now TWBlue will play a sound when the focused tweet contains images."
msgstr ""
#: ../doc/changelog.py:35
msgid ""
"* Your own quoted tweets will not appear in the mentions buffer anymore."
msgstr ""
#: ../doc/changelog.py:36
msgid ""
"* The config file is saved in a different way, it should fix the bug where "
"TWBlue needs to be restarted after the config folder is deleted."
msgstr ""
#: ../doc/changelog.py:37
msgid "* Mentioning people from friends or followers buffers works again."
msgstr ""
#: ../doc/changelog.py:38
msgid ""
"* Support for proxy servers has been improved. Now TWBlue supports http, "
"https, socks4 and socks5 proxies, with and without autentication."
msgstr ""
#: ../doc/changelog.py:39
msgid "## Changes in version 0.87"
msgstr ""
#: ../doc/changelog.py:40
msgid "* Fixed stream connection errors."
msgstr ""
#: ../doc/changelog.py:41
msgid ""
"* Now TWBlue can handle properly a reply to the sender without including all "
"other mentioned users."
msgstr ""
#: ../doc/changelog.py:42
msgid "* Updated translations."
msgstr ""
#: ../doc/changelog.py:43
msgid ""
"* The status of the mention to all checkbox will be remembered the next time "
"you reply to multiple users."
msgstr ""
#: ../doc/changelog.py:44
msgid "## Changes in version 0.86"
msgstr ""
#: ../doc/changelog.py:45
msgid ""
"* Fixed a very important security issue. Now TWBlue will send tweets to "
"twishort without using any other server."
msgstr ""
#: ../doc/changelog.py:46
msgid ""
"* When you add a comment to a tweet, it will be sent as a quoted tweet, even "
"if your reply plus the original tweet is not exceeding 140 characters."
msgstr ""
#: ../doc/changelog.py:47
msgid ""
"* Updated windows 10 keymap for reflecting changes made in the last windows "
"10 build."
msgstr ""
#: ../doc/changelog.py:48
msgid "* Added last changes in the twitter API."
msgstr ""
#: ../doc/changelog.py:49
msgid ""
"* When replying, it will not show the twitter username in the text box. When "
"you send the tweet, the username will be added automatically."
msgstr ""
#: ../doc/changelog.py:50
msgid ""
"* When replying to multiple users, you'll have a checkbox instead a button "
"for mentioning all people. If this is checked, twitter usernames will be "
"added automatically when you send your reply."
msgstr ""
#: ../doc/changelog.py:51
msgid "## Changes in version 0.85"
msgstr ""
#: ../doc/changelog.py:52
msgid "* Long and quoted tweets should be displayed properly In lists."
msgstr ""
#: ../doc/changelog.py:53
msgid "* The connection should be more stable."
msgstr ""
#: ../doc/changelog.py:54
msgid "* Added an autostart option in the global settings dialogue."
msgstr ""
#: ../doc/changelog.py:55
msgid "* Updated translation."
msgstr ""
#: ../doc/changelog.py:56
msgid "* Updated russian documentation."
msgstr ""
#: ../doc/changelog.py:57
msgid "* Tweets in cached database should be loaded properly."
msgstr ""
#: ../doc/changelog.py:58
msgid "* Added some missed dictionaries for spelling correction."
msgstr ""
#: ../doc/changelog.py:59
msgid ""
"* Timelines, lists and other buffer should be created in the right order at "
"startup."
msgstr ""
#: ../doc/changelog.py:60
msgid "## Changes in version 0.84 "
msgstr ""
#: ../doc/changelog.py:61
msgid "* More improvements in quoted and long tweets."
msgstr ""
#: ../doc/changelog.py:62
msgid ""
"* Updated translations: Russian, Italian, French, Romanian, Galician and "
"Finnish."
msgstr ""
#: ../doc/changelog.py:63
msgid ""
"* Improvements in the audio uploader module: Now it can handle audio with "
"non-english characters."
msgstr ""
#: ../doc/changelog.py:64
msgid ""
"* the title of the window should be updated properly when spellcheck, "
"translate or shorten/unshorten URL buttons are pressed."
msgstr ""
#: ../doc/changelog.py:65
msgid ""
"* the bug that changes the selected tweet in the home timeline shouldn't be "
"happening so often."
msgstr ""
#: ../doc/changelog.py:66
msgid "## Changes in version 0.82 and 0.83"
msgstr ""
#: ../doc/changelog.py:67
msgid ""
"* If the tweet source (client) is an application with unicode characters "
"(example: российская газета) it will not break the tweet displayer."
msgstr ""
#: ../doc/changelog.py:68
msgid ""
"* Added a new field for image description in tweet displayer. When "
"available, it will show description for images posted in tweets."
msgstr ""
#: ../doc/changelog.py:69
msgid ""
"* users can add image descriptions to their photos. When uploading an image, "
"a dialog will show for asking a description."
msgstr ""
#: ../doc/changelog.py:70
msgid "* Redesigned upload image dialog."
msgstr ""
#: ../doc/changelog.py:71
msgid "* Fixed photo uploads when posting tweets."
msgstr ""
#: ../doc/changelog.py:72
msgid ""
"* When getting tweets for a conversation, ignores deleted tweets or some "
"errors, now TWBlue will try to get as much tweets as possible, even if some "
"of these are no longer available."
msgstr ""
#: ../doc/changelog.py:73
msgid "* Added audio playback from soundcloud."
msgstr ""
#: ../doc/changelog.py:74
msgid "* Now the session mute option don't makes the screen reader speaks."
msgstr ""
#: ../doc/changelog.py:75
msgid "* Fixed the direct message dialog. Now it should be displayed properly."
msgstr ""
#: ../doc/changelog.py:76
msgid ""
"* when a tweet is deleted in twitter, TWBlue should reflect this change and "
"delete that tweet in every buffer it is displayed."
msgstr ""
#: ../doc/changelog.py:77
msgid ""
"* If your session is broken, TWBlue will be able to remove it automatically "
"instead just crashing."
msgstr ""
#: ../doc/changelog.py:78
msgid "* audio uploader should display the current progress."
msgstr ""
#: ../doc/changelog.py:79
msgid ""
"* users can disable the check for updates feature at startup from the "
"general tab, in the global settings dialogue."
msgstr ""
#: ../doc/changelog.py:80
msgid ""
"* The invisible interface and the window should be synchronized when the "
"client reconnects."
msgstr ""
#: ../doc/changelog.py:81
msgid "* The documentation option in the systray icon should be enabled."
msgstr ""
"* Sistemaren ikonoetako dokumentazioa ikusteko aukera erabilgarria egon "
"beharko litzateke."
#: ../doc/changelog.py:82
msgid ""
"* In trending buffers, you can press enter for posting a tweet about the "
"focused trend."
msgstr ""
"* Tendentzien buferretan, enter saka dezakezu enfokatutako tendentziari "
"buruz txio bat argitaratzeko."
#: ../doc/changelog.py:83
msgid ""
"* Updated russian documentation and main program interface (thanks to "
"Natalia Hedlund (Наталья Хедлунд), [@lifestar_n](https://twitter.com/"
"lifestar_n) in twitter)"
msgstr ""
#: ../doc/changelog.py:84
msgid "* updated translations."
msgstr "* Itzulpenak eguneratuak izan dira."
#: ../doc/changelog.py:85
msgid "## Changes in Version 0.81"
msgstr "## 0.81bertsioaren aldaketak"
#: ../doc/changelog.py:86
msgid "* Updated translations"
msgstr "* Itzulpenak eguneratuak izan dira"
#: ../doc/changelog.py:87
msgid ""
"* The updater module has received some improvements. Now it includes a "
"Mirror URL for checking updates if the main URL is not available at the "
"moment. If something is wrong and both locations don't work, the program "
"will start anyway."
msgstr ""
#: ../doc/changelog.py:88
msgid "* some GUI elements now use keyboard shortcuts for common actions."
msgstr ""
"* Interfaze grafikoko elementu batzuek lasterbide teklak dituzte ohiko "
"ekintzetarako."
#: ../doc/changelog.py:89
msgid "* fixed a bug in the geolocation dialog."
msgstr "* Errore bat konpondu da geottxioen elkarrizketa-koadroan."
#: ../doc/changelog.py:90
msgid "* the chicken nugget keymap should work properly."
msgstr "* Chicken Nuggetaren teklatu-mapak ondo funtzionatu beharko luke."
#: ../doc/changelog.py:91
msgid ""
"* Added a new soundpack to the default installation of TWBlue, thanks to "
"[@Deng90](https://twitter.com/deng90)"
msgstr ""
"* Soinu pakete berri bat gehitu zaio TWBlueren lehenetsitako instalazioari, "
"eskerrak [@Deng90](https://twitter.com/deng90)"
#: ../doc/changelog.py:92
msgid "* Now the changelog is written in an html File."
msgstr "* Orain aldaketen fitxategia html fitxategi bat da."
#: ../doc/changelog.py:93
msgid ""
"* Added some missed dictionaries in last version for the spell checking "
"feature."
msgstr ""
"* Aurreko bertsioan falta ziren hiztegi batzuk gehitu dira, zuzentzaleak "
"erabiltzen dituenak."
#: ../doc/changelog.py:94
msgid ""
"* Trimmed the beginnings of the sounds in the default soundpack. Thanks to "
"[@masonasons](https://github.com/masonasons)"
msgstr ""
"* ehenetsitako soiinu paketearen soinuen hasierak moztu dira. Eskerrak "
"[@masonasons-i.](https://github.com/masonasons)"
#: ../doc/changelog.py:95
msgid ""
"* Added Opus support for sound playback in TWBlue. Thanks to [@masonasons]"
"(https://github.com/masonasons)"
msgstr ""
"* Opus formatua erreproduzi daiteke, eskerrak [@masonasons-i.](https://"
"github.com/masonasons)."
#: ../doc/changelog.py:96
msgid ""
"* Added a source field in view tweet dialogue. Thanks to [@masonasons]"
"(https://github.com/masonasons)"
msgstr ""
"* \"Iturria\" gehitu zaio txioa erakusteko elkarrizketa koadroari. Eskerrak "
"[@masonasons-i.](https://github.com/masonasons)"
#: ../doc/changelog.py:97
msgid ""
"* You can load previous items in followers and friend buffers for others."
msgstr ""
"* Aurreko elementuak karga ditzakezu besteen jarraitzaile eta lagunen "
"buferretan."
#: ../doc/changelog.py:98
msgid ""
"* The Spell Checker dialogue should not display an error message when you "
"have set \"default language\" in the global settings dialogue if your "
"language is supported [#168](http://twblue.es/bugs/view.php?id=168)"
msgstr ""
"* Zuzentzailearen elkarrizketa-koadroak ez luke errorerik erakutsi behar "
"aukera globaletan \"Lehenetsitako hizkuntza\" aukeratua dagoenean eta zure "
"hizkuntza erabilgarria denean [#168](http://twblue.es/bugs/view.php?id=168)"
#: ../doc/changelog.py:99
msgid "* Updated romanian translation."
msgstr "* Errumaniera itzulpena eguneratua izan da."
#: ../doc/changelog.py:100
msgid "* Some code cleanups."
msgstr "* Kode garbiketa batzuk."
#: ../doc/changelog.py:101
msgid "* The bug reports feature is fully operational again."
msgstr "* Arazoez informatzeko ezaugarriak berriz funtzionaten du"
#: ../doc/changelog.py:102
msgid ""
"* TWBlue should work again for users that contains special characters in "
"windows usernames."
msgstr ""
"* TWBluek berriz funtzionatu beharko luke haien Windows erabiltzaile-"
"izenetan karaktere bereziak dituzten erabiltzaileentzat."
#: ../doc/changelog.py:103
msgid "* Added more options for the tweet searches."
msgstr "* Txioen bilaketarako aukera gehiago gehitu dira."
#: ../doc/changelog.py:104
msgid "* Added play_audio to the keymap editor."
msgstr "* play_audio teklatu-mapen editorera gehitua izan da."
#: ../doc/changelog.py:105
msgid "* Windows key is no longer required in the keymap editor"
msgstr "* Windows tekla ez da jada bearrezkoa teklatu-mapen editorean."
#: ../doc/changelog.py:106
msgid "* Switched to the Microsoft translator."
msgstr "* Microsoften itzultzailera aldatu gara."
#: ../doc/changelog.py:107
msgid ""
"* You can update the current buffer by pressing ctrl+win+shift+u in the "
"default keymap or in the buffer menu."
msgstr ""
"* Enfokatutako uferra ktrl+shift+win+u sakatuta (lehenetsitako teklatu-"
"mapak) edo menuan eguneratu daitezke."
#: ../doc/changelog.py:108
msgid "* Changed some keystrokes in the windows 10 default keymap"
msgstr ""
"* Lasterbide-tekla batzuk aldatuak izan dira Windows 10erako teklatu-mapan."
#: ../doc/changelog.py:109
msgid "* New followers and friends buffer for user timelines."
msgstr ""
"* Jarraitzaileen eta lagunen bufer berria erabiltzaileen denbora-lerroentzat."
#: ../doc/changelog.py:110
msgid "---"
msgstr "---"
#: ../doc/changelog.py:111
msgid "Copyright © 2014-2017, Manuel Cortez."
msgstr "Copyright © 2014-2017, Manuel Cortez."

View File

@@ -5,7 +5,7 @@
msgid ""
msgstr ""
"Project-Id-Version: TW Blue documentation 0.46\n"
"POT-Creation-Date: 2019-03-17 13:34+Hora estndar romance\n"
"POT-Creation-Date: 2019-03-17 13:34\n"
"PO-Revision-Date: 2015-11-27 08:33-0600\n"
"Last-Translator: Manuel Cortéz <manuel@manuelcortez.net>\n"
"Language-Team: Sukil Echenique <sukiletxe@yahoo.es>\n"

Binary file not shown.

View File

@@ -5,7 +5,7 @@
msgid ""
msgstr ""
"Project-Id-Version: \n"
"POT-Creation-Date: 2019-03-17 13:34+Hora estndar romance\n"
"POT-Creation-Date: 2019-03-17 13:34\n"
"PO-Revision-Date: 2018-08-07 13:52-0500\n"
"Last-Translator: Manuel Cortez <manuel@manuelcortez.net>\n"
"Language-Team: \n"

Binary file not shown.

View File

@@ -5,7 +5,7 @@
msgid ""
msgstr ""
"Project-Id-Version: TW Blue documentation 0.46\n"
"POT-Creation-Date: 2019-03-17 13:34+Hora estndar romance\n"
"POT-Creation-Date: 2019-03-17 13:34\n"
"PO-Revision-Date: 2018-08-27 16:37+0200\n"
"Last-Translator: Jani Kinnunen <jani.kinnunen@wippies.fi>\n"
"Language-Team: \n"

View File

@@ -5,7 +5,7 @@
msgid ""
msgstr ""
"Project-Id-Version: twblue-changelog 0.93\n"
"POT-Creation-Date: 2019-03-17 13:34+Hora estándar romance\n"
"POT-Creation-Date: 2019-03-17 13:34\n"
"PO-Revision-Date: 2019-07-22 16:16+0200\n"
"Last-Translator: Corentin BACQUÉ-CAZENAVE <corentin@progaccess33.net>\n"
"Language-Team: Corentin BACQUÉ-CAZENAVE <corentin@progaccess.net>\n"

View File

@@ -5,7 +5,7 @@
msgid ""
msgstr ""
"Project-Id-Version: TW Blue documentation 0.88\n"
"POT-Creation-Date: 2019-03-17 13:34+Hora estndar romance\n"
"POT-Creation-Date: 2019-03-17 13:34\n"
"PO-Revision-Date: 2018-08-11 12:25+0200\n"
"Last-Translator: Rémy Ruiz <remyruiz@gmail.com>\n"
"Language-Team: Rémy Ruiz <remyruiz@gmail.com>\n"

View File

@@ -5,7 +5,7 @@
msgid ""
msgstr ""
"Project-Id-Version: \n"
"POT-Creation-Date: 2019-03-17 13:34+Hora estndar romance\n"
"POT-Creation-Date: 2019-03-17 13:34\n"
"PO-Revision-Date: 2019-05-12 22:19+0100\n"
"Last-Translator: \n"
"Language-Team: \n"

View File

@@ -5,7 +5,7 @@
msgid ""
msgstr ""
"Project-Id-Version: tw blue documentation 0.46\n"
"POT-Creation-Date: 2019-03-17 13:34+Hora estndar romance\n"
"POT-Creation-Date: 2019-03-17 13:34\n"
"PO-Revision-Date: 2018-08-08 11:34+0100\n"
"Last-Translator: Juan C. Buño <oprisniki@gmail.com>\n"
"Language-Team: Alba Quinteiro <alba_080695@hotmail.com>\n"

View File

@@ -5,7 +5,7 @@
msgid ""
msgstr ""
"Project-Id-Version: \n"
"POT-Creation-Date: 2019-03-17 13:34+Hora estndar romance\n"
"POT-Creation-Date: 2019-03-17 13:34\n"
"PO-Revision-Date: 2017-12-11 11:07-0600\n"
"Last-Translator: \n"
"Language-Team: \n"

View File

@@ -5,7 +5,7 @@
msgid ""
msgstr ""
"Project-Id-Version: TW Blue documentation 0.46\n"
"POT-Creation-Date: 2019-03-17 13:34+Hora estndar romance\n"
"POT-Creation-Date: 2019-03-17 13:34\n"
"PO-Revision-Date: 2015-11-27 08:34-0600\n"
"Last-Translator: Manuel Cortéz <manuel@manuelcortez.net>\n"
"Language-Team: \n"

View File

@@ -5,7 +5,7 @@
msgid ""
msgstr ""
"Project-Id-Version: \n"
"POT-Creation-Date: 2019-03-17 13:34+Hora estndar romance\n"
"POT-Creation-Date: 2019-03-17 13:34\n"
"PO-Revision-Date: 2017-12-11 11:07-0600\n"
"Last-Translator: \n"
"Language-Team: \n"

View File

@@ -5,7 +5,7 @@
msgid ""
msgstr ""
"Project-Id-Version: TW Blue documentation 0.46\n"
"POT-Creation-Date: 2019-03-17 13:34+Hora estndar romance\n"
"POT-Creation-Date: 2019-03-17 13:34\n"
"PO-Revision-Date: 2018-08-09 11:51+0100\n"
"Last-Translator: Chris Leo Mameli <llajta2012@gmail.com>\n"
"Language-Team: \n"

View File

@@ -5,7 +5,7 @@
msgid ""
msgstr ""
"Project-Id-Version: \n"
"POT-Creation-Date: 2019-03-17 13:34+Hora estndar romance\n"
"POT-Creation-Date: 2019-03-17 13:34\n"
"PO-Revision-Date: 2018-08-08 19:52+0900\n"
"Last-Translator: \n"
"Language-Team: \n"

View File

@@ -5,7 +5,7 @@
msgid ""
msgstr ""
"Project-Id-Version: \n"
"POT-Creation-Date: 2019-03-17 13:34+Hora estndar romance\n"
"POT-Creation-Date: 2019-03-17 13:34\n"
"PO-Revision-Date: 2018-08-08 19:09+0900\n"
"Last-Translator: Masamitsu Misono <misono@nvsupport.org>\n"
"Language-Team: NVDA Help Desk <nvdahelp@center-aikoh.net>\n"

View File

@@ -5,7 +5,7 @@
msgid ""
msgstr ""
"Project-Id-Version: \n"
"POT-Creation-Date: 2019-03-17 13:34+Hora estndar romance\n"
"POT-Creation-Date: 2019-03-17 13:34\n"
"PO-Revision-Date: 2017-12-11 11:08-0600\n"
"Last-Translator: zvonimir stanecic <zvonimirek222@yandex.com>\n"
"Language-Team: \n"

View File

@@ -5,7 +5,7 @@
msgid ""
msgstr ""
"Project-Id-Version: TW Blue documentation 0.46\n"
"POT-Creation-Date: 2019-03-17 13:34+Hora estndar romance\n"
"POT-Creation-Date: 2019-03-17 13:34\n"
"PO-Revision-Date: 2017-01-22 21:42+0100\n"
"Last-Translator: Zvonimir Stanečić <zvonimirek222@yandex.com>\n"
"Language-Team: \n"

View File

@@ -5,7 +5,7 @@
msgid ""
msgstr ""
"Project-Id-Version: \n"
"POT-Creation-Date: 2019-03-17 13:34+Hora estndar romance\n"
"POT-Creation-Date: 2019-03-17 13:34\n"
"PO-Revision-Date: 2017-12-11 11:08-0600\n"
"Last-Translator: \n"
"Language-Team: \n"

View File

@@ -5,7 +5,7 @@
msgid ""
msgstr ""
"Project-Id-Version: TW Blue documentation 0.46\n"
"POT-Creation-Date: 2019-03-17 13:34+Hora estndar romance\n"
"POT-Creation-Date: 2019-03-17 13:34\n"
"PO-Revision-Date: 2015-11-27 08:35-0600\n"
"Last-Translator: Manuel Cortéz <manuel@manuelcortez.net>\n"
"Language-Team: \n"

View File

@@ -1,285 +0,0 @@
% Documentação do TW Blue 0.42
# Versão 0.42 (alpha)
# ¡Perigro!
Você está lendo um documento gerado para uma aplicação em fase de desenvolvimento. A intenção deste manual é esclarecer alguns detalhes sobre o funcionamento do programa. Note-se que sendo desenvolvido ativamente, o software pode mudar um pouco em relação a esta documentação num futuro próximo. Por isso é aconselhável dar uma olhada de vez em quando para não se perder muito.
Si quieres ver lo que ha cambiado con respecto a la versión anterior, [lee la lista de novedades aquí.](changes.html)
# TW Blue
TW Blue é um aplicativo para utilizar o Twitter de forma simples e rápida, além de evitar tanto quanto possível consumir demasiados recursos do computador. Com ele é possível realizar ações do Twitter, tais como:
* Crear, responder, reenviar y eliminar Tuits,
* Marcar como favorito, eliminar de tus favoritos un tuit,
* Enviar y eliminar mensajes directos,
* Ver tus amigos y seguidores,
* Seguir, dejar de seguir, reportar como spam y bloquear a un usuario,
* Abrir una línea temporal para un usuario, lo que permite obtener todos los Tuits de ese usuario únicamente,
* Abrir direcciones URL cuando vayan en un tuit o mensaje directo,
* Reproducir varios tipos de archivos o direcciones que contengan audio.
* Y más.
# Tabla de contenidos
Para poder utilizar una aplicación como TW Blue que te permita gestionar una cuenta de Twitter, primero tienes que estar registrado en esta red social. Esta documentación no tiene como objetivo explicar el procedimiento para hacerlo. Partiremos desde el punto que tienes una cuenta con su respectivo nombre de usuario y contraseña. La documentación cubrirá estas secciones.
* [Autorizar la aplicación](#autorizar)
* [La interfaz del programa](#interfaz)
* [Controles](#controles)
* [La interfaz gráfica (GUI)](#gui)
* [Botones de la aplicación](#botones)
* [Menús](#menus)
* [Menú aplicación](#app)
* [Menú Tuit](#tuit)
* [Menú Usuario](#usuario)
* [Menú buffer](#buffer)
* [Menú ayuda](#ayuda)
* [La interfaz No Visible](#interfaz_no_visible)
* [Atajos de Teclado para la Interfaz Gráfica](#atajos)
* [Atajos de Teclado para la Interfaz no Visible](#atajos_invisibles)
* [Listas](#listas)
* [Reportando Errores desde la web](#reportar)
* [Contacto](#contacto)
## Autorizando la aplicación {#autorizar}
Antes de nada, lo primero que se necesita es autorizar al programa para que este pueda acceder a tu cuenta de Twitter, y desde ella realizar lo que le pidas. El proceso de autorización es bastante sencillo, y en ningún momento el programa podrá tener acceso a tus datos como usuario y contraseña. Para autorizar la aplicación, solo tienes que abrir el archivo principal del programa, llamado TW Blue.exe (en algunos PC, solo se muestra como TW Blue).
Al hacerlo, si no has configurado ninguna vez el programa, se mostrará un cuadro de diálogo donde te informa que serás llevado a Twitter para autorizar la aplicación una vez pulses sobre "aceptar". Para empezar con el proceso de autorización presiona sobre el único botón de ese diálogo.
A continuación, tu navegador predeterminado se abrirá con la página de Twitter solicitándote autorizar la aplicación. Escribe, si no estás autenticado ya, tu nombre de usuario y contraseña, luego busca el botón autorizar, y presiónalo.
De la página a la que serás redirigido (si el proceso ha tenido éxito), busca las instrucciones que te proporciona Twitter. En resumen, te dará un código numérico de varios dígitos que deberás pegar en un cuadro de texto que la aplicación ha abierto en otra ventana.
Pega el código de verificación, y pulsa la tecla Intro.
Si todo ha salido bien, la aplicación empezará a reproducir un grupo de sonidos en señal que se están actualizando tus datos.
Cuando termine, el programa reproducirá otro sonido, y el lector de pantalla dirá "listo".
## La interfaz del programa {#interfaz}
La forma más simple de describir la interfaz gráfica de la aplicación es la de una ventana con una barra de menú con cinco menús (aplicación, tuit, usuario, buffer y ayuda); una lista de varios elementos y en la mayoría de los casos tres botones. Tuit, retuit y responder. Las acciones para cada uno de estos elementos serán descritas más adelante.
Los elementos que hay en las listas pueden ser Tuits, mensajes directos o usuarios. TW Blue crea diferentes pestañas para cada lista, pues estos elementos pueden ser Tuits enviados, Tuits recividos en la línea principal, favoritos, o mensajes directos, y cada pestaña tiene un solo tipo de Tuit. Estas pestañas se llaman listas o buffers.
Para cambiar entre las listas se hace presionando Control+Tab si se desea avanzar, y Control+Shift+Tab para retroceder. En todo momento los lectores de pantalla anunciarán la lista hacia la que se cambie el foco de la aplicación. Aquí están las listas básicas de TW Blue, que aparecen si se usa la configuración por defecto.
* Principal: Aquí van todos los Tuits que se muestran en la línea principal. Estos son los Tuits de los usuarios a los que sigues.
* Menciones: Si un usuario (lo sigas o no) te menciona en Twitter, lo verás en esta lista.
* Mensajes directos: Aquí están los mensajes directos (privados) que intercambias con los usuarios que sigues y te siguen. Esta lista solo muestra los mensajes recividos.
* Enviados: En esta lista se muestran todos los Tuits y mensajes directos que se han enviado desde tu cuenta.
* Favoritos: Aquí verás los Tuits que has marcado como favoritos.
* Seguidores: Cuando los usuarios sigan tu cuenta, podrás verlos en esta lista, junto con un poco de información de la cuenta.
* Amigos: Igual que la lista anterior, pero estos usuarios son a los que tú sigues.
* Eventos: Un evento en TW Blue es "algo" que pase en Twitter. En la línea de eventos, podrás ver registrados los eventos más comunes (p. Ej. Te han comenzado a seguir, han marcado o removido un tweet tuyo de los favoritos, te has suscrito a una lista). Son como pequeñas notificaciones que envía Twitter y TW Blue organiza para que no te pierdas lo que ha pasado con tu cuenta.
* Línea temporal de un usuario: Estas son listas que tú deberás crear. Es una lista que contiene únicamente los Tuits de un usuario. Se usan si algún día necesitas o quieres ver los Tuits que ha realizado solo una persona y no deseas buscar por todo tu timeline. Puedes crear tantas como usuarios necesites.
* Lista: Una lista es parecida a una línea temporal, pero compuesta por los tweets de cada usuario que forme parte de ella. De momento las listas son una característica experimental de TW Blue. Si experimentas problemas con ellas, por favor escríbenos para contárnoslo.
* Búsqueda: Un buffer de búsqueda contiene los resultados de una búsqueda hecha en TW Blue. Las búsquedas pueden ser por tuits, en cuyo caso buscas un término en los tuits relevantes de Twitter, o por usuarios, donde los resultados son nombres de usuario de Twitter.
* Favoritos de un usuario: Es posible pedirle a TW Blue que te muestre los tuits que un usuario ha marcado como favoritos.
Nota: Únicamente para esta versión de TW Blue, los amigos y seguidores actualizarán hasta 400, o cerca a los 400. En la próxima versión proporcionaremos un método para ver los amigos y seguidores sin exponerse tanto a los errores causados por el uso de la API de Twitter, muy frecuente entre personas con más de 600 amigos o seguidores.
Ten en cuenta que por defecto la configuración solo permite obtener los 200 últimos Tuits para las listas principal, menciones, mensajes directos y líneas temporales. Esto puedes cambiarlo desde el diálogo de configuración. Para los enviados se obtendrán los últimos 200 Tuits y 200 mensajes directos. En versiones futuras se permitirá ajustar este parámetro.
Si hay una dirección URL en algún tuit, TW Blue intentará abrirla cuando presiones Intro sobre ella. Si hay más de una, te mostrará una lista con todas para que selecciones la que quieras abrir. Si estás en el cuadro de diálogo de los amigos o seguidores, la tecla intro te mostrará detalles del mismo.
Si pulsas Control+Intro, TW Blue intentará reproducir el audio que tenga el tuit sobre el que está el foco del sistema, siempre que tenga una URL. Si el tuit lleva la etiqueta #audio, un sonido al pasar por él te alertará que es un audio y puedes intentar reproducirlo. No obstante, también puede que no esté etiquetado y que TW Blue pueda reproducirlo, siempre que lleve a una dirección URL donde exista audio.
## Controles {#controles}
A partir de la versión 0.36, existe soporte para una interfaz que no requiere de una ventana visible. Esta puede ser activada pulsando Control+m, o seleccionando desde el menú aplicación la opción "Esconder ventana". Esta interfaz se maneja completamente con atajos de teclado. Estos atajos son diferentes a los que se utilizan para la interfaz gráfica. Cada una de ellas podrá utilizar solo los atajos que le correspondan, lo que quiere decir que no se permitirá utilizar los atajos de la interfaz no visible si se tiene activada la interfaz gráfica. En esta sección se detallará tanto la interfaz gráfica como la no visible.
### Interfaz gráfica (GUI) {#gui}
Aquí una lista dividida en dos partes. Por un lado, los botones que encontrarás si presionas Tab o Shift+Tab en la interfaz del programa, y por otro, los diferentes elementos que hay en la barra de menú.
#### Botones de la aplicación {#botones}
* Twit: Este botón abre el diálogo para escribir un tuit. El mensaje solo debe tener 140 caracteres. Al escribir el caracter número 141, un sonido será reproducido para indicarte que te has pasado del límite permitido por Twitter. Puedes querer acortar o desacortar una URL si la incluye tu tuit a fin de ganar más espacio donde escribir, para eso están los botones con esos nombres. Pulsa Intro para enviar el tuit. Si todo sale bien, el mensaje se enviará y tú escucharás un sonido que te lo confirme, si no, el lector de pantalla te responderá con un error en inglés, que indica por qué no se ha podido enviar el mensaje.
* Retuit: Este botón se encarga de reenviar el tuit sobre el que estás leyendo. Al presionarlo se te preguntará si deseas añadirle un comentario al tuit original (citándolo) o simplemente enviarlo como se ha escrito sin añadir nada más.
* Responder: Cuando estés visualizando un Tuit, puedes responderle al usuario que lo escribió pulsando sobre este botón. Se abrirá el mismo diálogo de Tuit, pero con el nombre del usuario (por ejemplo @usuario) en el, para que solo escribas el mensaje que quieres responderle. Si en el tuit hay más de un usuario mencionado, pulsa Shift+Tab y pulsa el botón "Mencionar a todos los usuarios". Cuando estés en la lista de amigos o seguidores, este botón se llamará mencionar.
* mensaje directo: Exactamente igual que enviar un Tuit, pero es un mensaje privado que solo podrá ver el usuario al que se lo envías. Pulsa Shift+Tab para ver el destinatario de tu mensaje. Si en el Tuit donde estabas para enviar el mensaje había más de un usuario mencionado, puedes navegar con las flechas de arriba y abajo para seleccionar otro, o escribir tú mismo el usuario (sin el signo de arroba).
Ten en cuenta que los botones aparecerán según las acciones que se puedan hacer en la lista donde estés. Por ejemplo, en la línea principal, menciones, enviados, favoritos y las líneas temporales de los usuarios podrás ver los cuatro botones; mientras que en la lista de mensajes directos solo estará disponible el botón de "Mensaje Directo" y "tuit", y en las listas de amigos y seguidores, se verá el botón para "Twit" y el de "Mensaje directo" junto a "mencionar".
#### Menús {#menus}
En la parte superior de la ventana del programa podrás encontrar una barra de menú que hace las mismas cosas, y algunas cuantas más. A la barra de menú se accede presionando la tecla ALT, y cuenta en este momento con cuatro menús para diferentes acciones: Aplicación, Tuit, usuario y Ayuda. En esta sección se describen las acciones para cada uno de ellos.
##### Menú aplicación {#app}
* Actualizar Perfil: Abre un diálogo desde donde se podrá actualizar parte de tu información en Twitter. Nombre, ubicación, dirección URL y descripción. Si ya tienes alguno de estos campos actualmente en el perfil se llenarán automáticamente con lo que tiene tu configuración de Twitter. También podrás subir una foto a tu perfil.
* Esconder Ventana: Desactiva la interfaz gráfica. Lee el apartado sobre la interfaz no visible para más detalles sobre este comportamiento.
* Búsqueda: Muestra un cuadro de diálogo desde donde puedes buscar por tuits o por usuarios en twitter.
* Gestor de listas: Para poder utilizar las listas de Twitter, primero necesitarás crearlas. Este diálogo permite ver tus listas, editarlas, crearlas, borrarlas y, opcionalmente, verlas en buffers tal como lo harías con las líneas temporales.
* Tutorial de sonidos: Abre un diálogo donde verás una lista de los sonidos de TW blue, para que puedas aprenderlos y no te cueste trabajo familiarizarte con TW Blue.
* Preferencias: Abre un diálogo de configuración desde donde se pueden controlar algunos aspectos del programa. Las opciones no necesitan de explicación.
* Salir: pregunta si quieres salir o no del programa. Si la respuesta es que sí, cierra la aplicación.
##### Menú Tuit {#tuit}
* Las primeras opciones del menú son Twit, responder y retuit, que corresponden a los botones del mismo nombre.
* Marcar como favorito: Marca el tuit que estés viendo como favorito.
* Quitar tuit de favoritos: Elimina el tuit de tus favoritos. Esto no significa que se borra de Twitter, solo deja de estar en tu lista de favoritos.
* Ver Tuit: Abre un diálogo donde puedes ver el Tuit, mensaje directo, amigo o seguidor sobre el que esté el foco de la aplicación. Puedes leer el texto con los cursores. El diálogo es el mismo que el que se usa para escribir un Tuit.
* Eliminar: Elimina el Tuit o mensaje directo sobre el que estés, borrándolo definitivamente de Twitter y qitándolo de tus listas. Ten en cuenta que en el caso de los Tuits, Twitter solo permite borrar los que tú mismo has escrito.
##### Menú usuario {#usuario}
Ten en cuenta que las primeras seis opciones de este menú abren un mismo diálogo. Este diálogo tiene un cuadro de edición donde puedes seleccionar el usuario sobre el que deseas actuar, bien con los cursores arriba y abajo o escribiendo tú mismo el nombre. Después, hay un grupo de botones de radio para seguir, dejar de seguir, silenciar, des-silenciar, reportar como Spam y bloquear. Si seleccionas desde el menú la opción seguir, el botón del cuadro de diálogo estará marcado con esa opción, así como sucederá respectivamente con dejar de seguir, reportar como Spam y bloquear. Pulsa el botón Aceptar para que el programa trate de hacer lo que le pides. Si no se ha podido, escucharás el error en inglés.
A continuación se describen las opciones restantes para este menú:
* Mensaje Directo: La misma acción que el botón.
* Añadir a lista: Para que puedas ver los tweets de un usuario en tus listas, primero hay que añadirlo. Esta opción abrirá un diálogo desde donde puedes seleccionar al usuario que deseas añadir, para después abrir otra ventana donde puedes seleccionar la lista a la cual añadir a ese usuario. Una vez hecho esto, la lista contendrá un nuevo usuario y podrás ver sus tweets.
* Ver Perfil del usuario: Abre un diálogo desde donde te permite seleccionar el usuario al que quieres ver el perfil.
* Línea temporal: Abre un diálogo desde donde puedes seleccionar el usuario para el que se creará la línea temporal. Al presionar intro, se creará. Si se hace una línea temporal de un usuario que no tenga Tuits, el programa fallará. Si se crea una línea que ya existe el programa te avisará y no permitirá crearla de nuevo.
* Ver favoritos: Abre un buffer para seguir los favoritos que marca el usuario seleccionado.
##### Menú Buffer {#buffer}
* Silenciar: Silencia completamente el buffer, con lo que no escucharás sonido alguno cuando nuevos elementos aparezcan.
* Leer automáticamente tuits para este buffer: Esta opción activa o desactiva la lectura automática de tuits. Si está activada, el lector de pantalla o la voz Sapi5 (si está activada una) leerá automáticamente los nuevos tuits conforme estos vayan llegando al buffer.
* Limpiar Buffer: Vacía los elementos de este buffer.
* Eliminar buffer: Borra la lista sobre la que te encuentras actualmente.
##### Menú Ayuda {#ayuda}
* Documentación: Abre este archivo, donde puedes leer algunos conceptos interesantes del programa.
* ¿Qué hay de nuevo en esta versión?: Abre un documento con la lista de cambios desde la versión actual, hasta la primera en existencia.
* Buscar actualizaciones: Cada que se abre el programa él mismo busca automáticamente si hay una nueva versión. Si lo hay, te preguntará si quieres descargarla; si aceptas, TW Blue descargará la actualización, la instalará y te pedirá reiniciarla (algo que hace automáticamente). Esta opción comprueba si hay actualizaciones sin tener que reiniciar la aplicación.
* Sitio web de TW Blue. Ve a nuestra [página principal](http://twblue.com.mx) donde podrás encontrar toda la información y descargas relativas a TW Blue, así como participar de la comunidad.
* Reportar un error: Lanza un diálogo desde donde puedes reportar un error solo llenando un par de campos. El título y una pequeña descripción de lo que pasó. Al pulsar en "enviar" el error se reportará. Si no se ha podido el programa te mostrará un mensaje informándolo.
* Sobre TW Blue: Muestra información de créditos del programa.
### Interfaz no visible {#interfaz_no_visible}
Si presionas Control+M, o si desde el menú aplicación seleccionas esconder ventana, estarás activando una interfaz a la que no se podrá acceder por la manera convencional, porque no se ve.
En la interfaz no visible todo lo que hagas será mediante atajos de teclado, incluso para recorrer las listas. Eventualmente se abrirán diálogos y estos sí serán visibles, pero la ventana principal de la aplicación no. Ve a la sección de atajos de teclado de la interfaz no visible para saber cuales puedes usar de momento.
### Atajos de teclado para la Interfaz Gráfica {#atajos}
Además de los botones y menús, la mayoría de las acciones pueden hacerse presionando una combinación de teclado. Aquí están las existentes en este momento:
* Intro: Abrir una dirección URL. Si hay más de una podrás ver una lista que te permitirá seleccionar la que quieras. Si estás en la lista de amigos o seguidores, mostrará detalles del seleccionado.
* Control+Intro: Intenta reproducir un audio si en el Tuit hay una dirección URL.
* F5: Baja un 5% el volumen de los sonidos. Esto afecta a los sonidos que reproduce el programa y al audio que puedas escuchar a través de él.
* F6: Sube un 5% el volumen de los sonidos de la aplicación.
* Control+N: Abre el diálogo para escribir un nuevo Tuit.
* Control+M: Oculta la ventana.
* Control+Q: Sale de la aplicación.
* Control+R: Abre el diálogo para responder.
* Control+Shift+R: Equivalente a la acción Retuit.
* Control+D: Enviar mensaje directo.
* Control+F: Marcar como favorito.
* Control+Shift+F: Quitar de favoritos.
* Control+Shift+V: Ver Tuit.
* Control+S: Seguir a un usuario.
* Control+Shift+S: Dejar de seguir a un usuario.
* Control+K: Bloquear a un usuario.
* Control+Shift+K: Reportar como Spam.
* Control+I: Abrir línea temporal a un usuario.
* Control+Shift+I: Eliminar línea temporal.
* Control+p: Editar tu perfil.
* Suprimir: Eliminar tuit o mensaje directo.
* Shift+suprimir: vacía el buffer, quitando todos los elementos hasta ese entonces. Esto ocurre sin borrar nada de Twitter.
### Atajos de teclado para la Interfaz no Visible {#atajos_invisibles}
Estos son los atajos de teclado que puedes usar desde la interfaz no visible. Ten en cuenta que cuando la vista de la interfaz gráfica esté activada ninguno de ellos podrá usarse. Al decir "windows", nos estamos refiriendo a la tecla de Windows izquierda.
* Control+Windows+Flecha Arriba: Va arriba en la lista actual.
* Control+Windows+Flecha abajo: Va hacia abajo en la lista actual.
* Control+Windows+Izquierda: Se desplaza a la pestaña de la izquierda.
* Control+Windows+Derecha: Se desplaza hacia la pestaña de la derecha.
* Control+Windows+Inicio: Ir al primer elemento de la lista.
* Control+Windows+Fin: Ir al final de la lista.
* Control+Windows+Avance de página: Ir 20 elementos hacia abajo en la lista actual.
* Control+Windows+Retroceso de página: ir 20 elementos hacia arriba en la lista actual.
* Control+Windows+Alt+Flecha Arriba: Subir volumen un 5%.
* Control+Windows+Alt+Flecha Abajo: Bajar volumen un 5%.
* Control+Windows+Intro: Abrir URL en el tuit, o ver detalles del usuario si estás en la lista de amigos o seguidores.
* Control+Windows+Alt+Intro: Intentar reproducir un audio.
* Control+Windows+M: Muestra la interfaz gráfica, desactivando la no visible.
* Control+Windows+N: Hacer un nuevo Tuit.
* Control+Windows+R: Responder a un tuit.
* Control+Windows+Shift+R: Hacer un retuit.
* Control+Windows+D: Enviar un mensaje directo.
* Control+Windows+Suprimir: Eliminar un tuit o mensaje directo.
* control+win+Shift+suprimir: vacía el buffer, quitando todos los elementos hasta ese entonces. Esto ocurre sin borrar nada de Twitter.
* Windows+Alt+F: Marcar como favorito.
* Windows+Alt+Shift+F: Quitar de favoritos.
* Control+Windows+S: Seguir a un usuario.
* Control+Windows+Shift+S: Dejar de seguir a alguien.
* Control+Windows+Alt+N: Ver detalles de un usuario,
* Control+Windows+V: Ver tuit en un cuadro de texto.
* Control+Windows+I: Abrir línea temporal.
* Control+Windows+Shift+I: Eliminar línea temporal de un usuario.
* Alt+Windows+P: Editar tu perfil.
* Control+win+espacio: ver tweet actual.
* Control+win+c: Copiar tweet al portapapeles.
* Control+windows+a: Añadir a un usuario a la lista.
* Control+shift+windows+a: qitar de la lista.
* Control+Windows+Shift+Flecha arriba: Ir un tuit hacia arriba en la conversación.
* Control+Windows+Flecha Abajo: Ir un tuit hacia abajo en la conversación.
* Control+Windows+Shift+M: Activar o desactivar el sonido para el buffer actual.
* Windows+Alt+M: Activar o desactivar el silencio global de TW Blue.
* Control+Windows+E: Activar o desactivar la lectura automática de los tuits en el buffer actual.
* Control+windows+Guion: buscar en Twitter.
* Control+Windows+F4: Cerrar el programa.
## Listas {#listas}
Una de las características más interesantes de Twitter son las listas, ya que son una manera de mantenerse actualizado sin tener que leer los tweets de todos los usuarios a los que sigues. Con una lista de Twitter solo verás los tweets de sus miembros (la gente que está dentro de la lista). Es parecido a una línea temporal, pero para muchos más usuarios.
En TW blue hemos empezado a dar soporte para esta característica. De momento vamos poco a poco, pero ya es posible usar esta función. Te presentamos los pasos que hay que dar para poder tener una lista abierta en TW Blue.
* Primero necesitarás ir al gestor de listas, ubicado bajo el menú aplicación.
* en el gestor de listas podrás ver todas las listas a las que estás unido, empezando por las que tú has creado. Si no ves ninguna lista en este diálogo, significa que no has creado ni te has unido a ninguna lista. Está bien.
* Verás un grupo de botones que se explican por sí solos: Crear nueva lista, editar, eliminar, abrir en buffer (este quizá es el menos claro, se refiere a abrir un nuevo buffer para que TW Blue actualice los tweets de la lista, como cuando pasa con las líneas temporales).
Una vez que hayas creado una nueva lista, no deberías abrirla en buffer. Al menos no de inmediato, porque en este momento no tiene miembro alguno y eso significa que cuando se carguen los tweets para empezar a actualizarla no verás nada. Es recomendable primero añadir a gente a la lista, tal como sigue:
* Cuando hayas cerrado el gestor de listas y estés navegando por entre los tweets de los usuarios, busca el usuario al que quieres añadir a la lista.
* Una vez encontrado, presiona el atajo Ctrl+Win+A o ve al menú usuario y selecciona la opción "Añadir a lista".
* Lo siguiente que verás es un diálogo que te permitirá seleccionar el usuario, asegúrate que el que está como predeterminado es el que deseas, o cámbialo si es necesario, y presiona Aceptar.
* Ahora verás otro diálogo, pero aquí están todas tus listas. Selecciona una (simplemente lleva el cursor hacia ella), y presiona el botón añadir.
* Para qitar a un usuario de una lista repite el mismo proceso, pero presiona Control+Win+Shift+A o selecciona la opción "Quitar de lista", y en el diálogo de las listas presiona sobre el botón "remover".
## Reportando Errores Desde la Web {#reportar}
Nota: Si estás usando el programa también puedes reportar un error desde el mismo, usando para ello la opción del menú ayuda. Este proceso solo te pide llenar dos cuadros de edición, y se encarga del resto. Estos pasos están escritos para quienes no pueden abrir el programa, no lo tienen en uso en este momento o sencillamente quieran reportar desde la web en lugar del sistema integrado de reporte de errores.
Las cosas en este mundo (sí, incluidos los programas informáticos) están muy lejos de ser perfectas, con lo que a menudo te encontrarás con errores no previstos en la aplicación. Pero como la intención es siempre mejorar, eres libre (es más, sería genial que lo hicieras) de reportar los errores que vayas encontrando del programa para que se puedan revisar y eventualmente corregir.
Para entrar a la web de reporte de incidencias, sigue [Este enlace.](http://twblue.com.mx/errores/bug_report_page.php) Es una web con un formulario donde tienes que llenar varios campos. Solo tres de ellos son realmente obligatorios (los que tienen marcado un asterisco), pero entre más campos puedas llenar, será mejor.
Aquí están los diferentes campos del formulario y lo que deberías introducir en cada uno de ellos. Recuerda que son obligatorios solamente los campos marcados con un asterisco (*):
* Categoría: Este cuadro combinado permite seleccionar a qué categoría asignar el error. Puede ser a la categoría General, si es un error del programa, o a documentación, si has encontrado un error en este archivo o en la lista de cambios. Este campo es obligatorio.
* Reproducibilidad: Aquí deberías indicar qué tan fácil o no es de reproducir el error. Las opciones disponibles son Desconocido, No reproducible, No se ha intentado (por defecto), aleatorio, a veces o siempre. Dependiendo de si se puede reproducir el error o no, deberías indicar lo que se parezca más a tu caso. Si estás solicitando una nueva funcionalidad, no importa este cuadro combinado.
* Severidad: Aquí se selecciona que tanto afecta esto al programa. Las opciones disponibles son funcionalidad (selecciona esto para solicitar una nueva funcionalidad), Trivial, Texto, Ajuste, Menor, Mayor, fallo o bloqueo. Nota que las opciones aumentan de nivel. Selecciona lo que más creas. Si no estás seguro de que seleccionar puedes dejarlo como está.
* Prioridad: En este cuadro se selecciona la opción de acuerdo con la importancia del error o funcionalidad solicitada. Las opciones disponibles son Ninguna, baja, normal, alta, hurgente e inmediata.
* Seleccionar Perfil: Aquí puedes escojer entre la configuración de arquitectura (32 o 64 bits), y el sistema operativo (Windows siete de momento). Si no, puedes llenar los tres cuadros de edición que están en la siguiente tabla con tus datos en específico.
* Versión del producto: Selecciona la versión del programa que estás utilizando para poder averiguar donde se ha generado el error. Este cuadro combinado tendrá la lista de las versiones en orden. Si bien no es obligatorio, ayudaría mucho a resolver más rápidamente el error.
* Resumen: Un título para el error, que explique en pocas palabras qué ocurre. Es un cuadro de texto obligatorio.
* Descripción: Este campo también obligatorio, te pide que describas con más detalles qué fue lo que ha ocurrido con el programa.
* Pasos para reproducir: Este campo de texto te sirve si sabes como hacer que la aplicación genere el error. Esto no es obligatorio, pero ayudaría mucho conocer como hacer que el programa tenga este error para rastrearlo mejor.
* Información adicional: Si tienes un comentario o nota que añadir, aquí puede ir. No es obligatorio.
* Subir archivo: Puedes subir aquí el archivo TW Blue.exe.log que se creó con el error que el programa tuvo. No es obligatorio.
* Visibilidad: Selecciona si quieres que el error sea público o privado. Por defecto es público, y es recomendable que así continúe.
* Enviar reporte. Presiona aquí para publicar el error y que este sea atendido.
Muchas gracias por participar reportando errores y probando las funciones nuevas.
## Contacto {#contacto}
Si lo que se expone en este documento no es suficiente, si deseas colaborar de alguna otra forma o si simplemente deseas mantenerte en contacto con quien hace esta aplicación, sigue a la cuenta [@tw_blue2](https://twitter.com/tw_blue2) o a [@manuelcortez00.](https://twitter.com/manuelcortez00) También puedes visitar nuestro [Sitio web](http://twblue.com.mx)
---
Copyright © 2013-2014. Manuel Cortéz.

File diff suppressed because it is too large Load Diff

View File

@@ -5,7 +5,7 @@
msgid ""
msgstr ""
"Project-Id-Version: twblue-documentation 0.46\n"
"POT-Creation-Date: 2019-03-17 13:34+Hora estndar romance\n"
"POT-Creation-Date: 2019-03-17 13:34\n"
"PO-Revision-Date: 2018-08-08 10:32+0300\n"
"Last-Translator: Florian Ionașcu <florianionascu@hotmail.com>\n"
"Language-Team: Spanish <manuel@manuelcortez.net>\n"

View File

@@ -5,7 +5,7 @@
msgid ""
msgstr ""
"Project-Id-Version: \n"
"POT-Creation-Date: 2019-03-17 13:34+Hora estndar romance\n"
"POT-Creation-Date: 2019-03-17 13:34\n"
"PO-Revision-Date: 2018-08-15 12:20+0400\n"
"Last-Translator: Наталья Хедлунд <natalia.hedlund@gmail.com>\n"
"Language-Team: \n"

View File

@@ -5,7 +5,7 @@
msgid ""
msgstr ""
"Project-Id-Version: TW Blue documentation 0.46\n"
"POT-Creation-Date: 2019-03-17 13:34+Hora estndar romance\n"
"POT-Creation-Date: 2019-03-17 13:34\n"
"PO-Revision-Date: 2018-08-14 21:44+0400\n"
"Last-Translator: Valeria <luciana.lu3a@gmail.com>\n"
"Language-Team: \n"

View File

@@ -5,7 +5,7 @@
msgid ""
msgstr ""
"Project-Id-Version: \n"
"POT-Creation-Date: 2019-03-17 13:34+Hora estándar romance\n"
"POT-Creation-Date: 2019-03-17 13:34\n"
"PO-Revision-Date: 2021-06-27 04:17+0100\n"
"Last-Translator: Nikola Jović <wwenikola123@gmail.com>\n"
"Language-Team: \n"

View File

@@ -5,7 +5,7 @@
msgid ""
msgstr ""
"Project-Id-Version: \n"
"POT-Creation-Date: 2019-03-17 13:34+Hora estándar romance\n"
"POT-Creation-Date: 2019-03-17 13:34\n"
"PO-Revision-Date: 2021-06-27 01:40+0100\n"
"Last-Translator: Nikola Jović <wwenikola123@gmail.com>\n"
"Language-Team: \n"

View File

@@ -5,7 +5,7 @@
msgid ""
msgstr ""
"Project-Id-Version: \n"
"POT-Creation-Date: 2019-03-17 13:34+Hora estndar romance\n"
"POT-Creation-Date: 2019-03-17 13:34\n"
"PO-Revision-Date: 2018-01-05 17:01+0300\n"
"Last-Translator: \n"
"Language-Team: \n"

View File

@@ -5,7 +5,7 @@
msgid ""
msgstr ""
"Project-Id-Version: TW Blue documentation 0.46\n"
"POT-Creation-Date: 2019-03-17 13:34+Hora estndar romance\n"
"POT-Creation-Date: 2019-03-17 13:34\n"
"PO-Revision-Date: 2019-02-03 17:01+0300\n"
"Last-Translator: Manuel Cortéz <manuel@manuelcortez.net>\n"
"Language-Team: \n"

View File

@@ -1,4 +1,4 @@
Documentation for TWBlue - 0.88
Documentation for TWBlue
## Table of contents
@@ -42,7 +42,7 @@ You can log into several Twitter accounts simultaneously. The program refers to
Your default browser will open on the Twitter page to request authorisation. Enter your username and password into the appropriate edit fields if you're not already logged in, select the authorise button, and press it.
Once you've authorised your twitter account, the website will redirect you to a page which will notify you that TWBlue has been authorised successfully. Now you are able to close the page by pressing ALT+F4 which will return you to the Session Manager. On the session list, you will see a new item temporarily called "Authorised account x" -where x is a number. The session name will change once you open that session.
Once you've authorised your twitter account, the website will redirect you to a page which will notify you that TWBlue has been authorised successfully. On this page, you will be shown a code composed of several numbers that you must paste in the TWBlue authorization dialogue in order to allow the application to access your account. Once you have pasted the code in the corresponding text field, press enter to finish the account setup and go back to the session manager. On the session list, you will see a new item temporarily called "Authorised account x" -where x is a number. The session name will change once you open that session.
To start running TWBlue, press the Ok button in the Session Manager dialogue. By default, the program starts all the configured sessions automatically, however, you can change this behavior.
@@ -56,7 +56,7 @@ Before starting to describe TWBlue's usage, we'll explain some concepts that wil
### Buffer
A buffer is a list of items to manage the data which arrives from Twitter, after being processed by the application. When you configure a new session on TWBlue and start it, many buffers are created. Each of them may contain some of the items which this program works with: Tweets, direct messages, users, trends or events. According to the buffer you are focusing, you will be able to do different actions with these items.
A buffer is a list of items to manage the data which arrives from Twitter, after being processed by the application. When you configure a new session on TWBlue and start it, many buffers are created. Each of them may contain some of the items which this program works with: Tweets, direct messages, users, trends or. According to the buffer you are focusing, you will be able to do different actions with these items.
The following is a description for every one of TWBlue's buffers and the kind of items they work with.
@@ -69,17 +69,17 @@ The following is a description for every one of TWBlue's buffers and the kind of
* Followers: when users follow you, you'll be able to see them on this buffer, with some of their account details.
* Friends: the same as the previous buffer, but these are the users you follow.
* User timelines: these are buffers you may create. They contain only the tweets by a specific user. They're used so you can see the tweets by a single person and you don't want to look all over your timeline. You may create as many as you like.
* Events: An event is anything that happens on Twitter, such as when someone follows you, when someone adds or removes one of your tweets from their likes list, or when you subscribe to a list. There are many more, but the program shows the most common ones in the events buffer so that you can easily keep track of what is happening on your account.
* Lists: A list is similar to a user timeline, except that you can configure it to contain tweets from multiple users.
* Search: A search buffer contains the results of a search operation.
* User likes: You can have the program create a buffer containing tweets liked by a particular user.
* Followers or following timeline: You can have TWBlue create a buffer containing all users who follow, or are followed by a specific user.
* Trending Topics: a trend buffer shows the top ten most used terms in a geographical region. This region may be a country or a city. Trends are updated every five minutes.
If a tweet contains a URL, you can press enter in the GUI or Control + Windows + Enter in the invisible interface to open it. If it contains audio, you can press Control + Enter or Control + Windows + Alt + Enter to play it, respectively. TWBlue will play a sound if the tweet contains the \#audio hashtag, but there may be tweets which contain audio without this. Finally, if a tweet contains geographical information, you can press Control + Windows + G in the invisible interface to retrieve it.
If a tweet contains a URL, you can press enter in the GUI or Control + Windows + Enter in the invisible interface to open it. If it contains video or audio, including live stream content, you can press Control + Enter or Control + Windows + Alt + Enter to play it, respectively. TWBlue will play a sound if the tweet contains video metadata or the \#audio hashtag, but there may be tweets which contain media without this. Finally, if a tweet contains geographical information, you can press Control + Windows + G in the invisible interface to retrieve it.
### Username fields
These fields accept a Twitter username (without the at sign) as the input. They are present in the send direct message and the user actions dialogue boxes. Those dialogues will be discussed later. The initial value of these fields depends on where they were opened from. They are prepopulated with the username of the sender of the focused tweet (if they were opened from the home and sent timelines, from users' timelines or from lists), the sender of the focused direct message (if from the received or sent direct message buffers) or in the focused user (if from the followers' or friends' buffer). If one of those dialogue boxes is opened from a tweet, and if there are more users mentioned in it, you can use the arrow keys to switch between them. Alternatively, you can also type a username.
These fields accept a Twitter username (without the at sign) as the input. They are present in the send direct message, the user actions dialogue and the user alias dialogue boxes, to name a few examples. Those dialogues will be discussed later. The initial value of these fields depends on where they were opened from. They are prepopulated with the username of the sender of the focused tweet (if they were opened from the home and sent timelines, from users' timelines or from lists), the sender of the focused direct message (if from the received or sent direct message buffers) or in the focused user (if from the followers' or friends' buffer). If one of those dialogue boxes is opened from a tweet, and if there are more users mentioned in it, you can use the arrow keys to switch between them. Alternatively, you can also type a username.
## The program's interfaces
@@ -98,9 +98,9 @@ In summary, the GUI contains two core components. These are the controls you wil
#### Buttons in the application
* Tweet: this button opens up a dialogue box to write your tweet. Normal tweets must not exceed 280 characters. However you can press the long tweet checkbox and your tweet will be posted throught Twishort, wich will allow you to write longer tweets (10000 characters). If you write past this limit, a sound will play to warn you. Note that the character count is displayed in the title bar. You may use the shorten and expand URL buttons to comply with the character limit. You can upload a picture, check spelling, attach audio or translate your message by selecting one of the available buttons in the dialogue box. In addition, you can autocomplete the entering of users by pressing Alt + C or the button for that purpose if you have the database of users configured. Press enter to send the tweet. If all goes well, you'll hear a sound confirming it. Otherwise, the screen reader will speak an error message in English describing the problem.
* Tweet: this button opens up a dialogue box to write your tweet. Normal tweets must not exceed 280 characters. However you can press the long tweet checkbox and your tweet will be posted throught Twishort, wich will allow you to write longer tweets (10000 characters). If you write past this limit, a sound will play to warn you. Note that the character count is displayed in the title bar. You can upload a picture, check spelling, attach audio or translate your message by selecting one of the available buttons in the dialogue box. In addition, you can autocomplete the entering of users by pressing Alt + C or the button for that purpose if you have the database of users configured. Press enter to send the tweet. If all goes well, you'll hear a sound confirming it. Otherwise, the screen reader will speak an error message in English describing the problem.
* Retweet: this button retweets the message you're reading. After you press it, if you haven't configured the application not to do so, you'll be asked if you want to add a comment or simply send it as written. If you choose to add a comment, it will post a quoted tweet, that is, the comment with a link to the originating tweet.
* Reply: when you're viewing a tweet, you can reply to the user who sent it by pressing this button. A dialogue will open up similar to the one for tweeting. If there are more users referred to in the tweet, you can press tab and activate the mention to all checkbox, or enabling checkbox for the users you want to mention separately. When you're on the friends or followers lists, the button will be called mention instead.
* Reply: when you're viewing a tweet, you can reply to the user who sent it by pressing this button. A dialogue will open up similar to the one for tweeting. If there are more users referred to in the tweet, you can press tab and activate the mention to all checkbox, or enabling checkbox for the users you want to mention separately. Note, however, that sometimes -especially when replying to a retweet or quoted tweet, the user who made the retweet or quote may also be mentioned. This is done by Twitter automatically. When you're on the friends or followers lists, the button will be called mention instead.
* Direct message: exactly like sending a tweet, but it's a private message which can only be read by the user you send it to. Press shift-tab twice to see the recipient. If there were other users mentioned in the tweet you were reading, you can arrow up or down to choose which one to send it to, or write the username yourself without the at sign. In addition, you can autocomplete the entering of users by pressing Alt + C or the button for that purpose if you have the database of users configured.
Bear in mind that buttons will appear according to which actions are possible on the list you are browsing. For example, on the home timeline, mentions, sent, likes and user timelines you will see the four buttons, while on the direct messages list you'll only get the direct message and tweet buttons, and on friends and followers lists the direct message, tweet, and mention buttons will be available.
@@ -116,6 +116,7 @@ Visually, Towards the top of the main application window, can be found a menu ba
* Hide window: turns off the Graphical User Interface. Read the section on the invisible interface for further details.
* Search: shows a dialogue box where you can search for tweets or users on Twitter.
* Lists Manager: This dialogue box allows you to manage your Twitter lists. In order to use them, you must first create them. Here, you can view, edit, create, delete or, optionally, open them in buffers similar to user timelines.
* Manage user aliases: Opens up a dialogue where you can manage user aliases for the active session. In this dialog you can add new aliases, as well as edit and delete existing ones.
* Edit keystrokes: this opens a dialogue where you can see and edit the shortcuts used in the invisible interface.
* Account settings: Opens a dialogue box which lets you customize settings for the current account.
* Global settings: Opens a dialogue which lets you configure settings for the entire application.
@@ -145,6 +146,7 @@ Visually, Towards the top of the main application window, can be found a menu ba
* Ignore tweets from this client: Adds the client from which the focused tweet was sent to the ignored clients list.
* View timeline: Lets you open a user's timeline by choosing the user in a dialog box. It is created when you press enter. If you invoke this option relative to a user that has no tweets, the operation will fail. If you try creating an existing timeline the program will warn you and will not create it again.
* Direct message: same action as the button.
* Add Alias: An user alias allows you to rename user's display names on Twitter, so the next time you'll read an user it will be announced as you configured. This feature works only if you have set display screen names unchecked, in account settings.
* Add to List: In order to see someone's tweets in one or more of your lists, you must add them first. In the dialogue box that opens after selecting the user, you will be asked to select the list you wish to add the user to. Thereafter, the list will contain a new member and their tweets will be displayed there.
* Remove from list: lets you remove a user from a list.
* View lists: Shows the lists created by a specified user.
@@ -153,8 +155,12 @@ Visually, Towards the top of the main application window, can be found a menu ba
##### Buffer menu
* Update buffer: Retrieves the newest items for the focused buffer. Normally, every buffer gets updated every couple of minutes, however you can force a specific buffer to be updated inmediately. Take into account, however, that the usage of this option repeatedly might exceed your allowed Twitter's API usage, in which case you would have to wait until it gets reset, tipycally within the next 15 minutes.
* New trending topics buffer: This opens a buffer to get the worlwide trending topics or those of a country or a city. You'll be able to select from a dialogue box if you wish to retrieve countries' trends, cities' trends or worldwide trends (this option is in the cities' list) and choose one from the selected list. The trending topics buffer will be created once the "OK" button has been activated within the dialogue box. Remember this kind of buffer will be updated every five minutes.
* Load previous items: This allows more items to be loaded for the specified buffer.
* Create filter: Creates a filter in the current buffer. Filters allow loading or ignoring tweets that meet certain conditions into a buffer. You can, for example, set a filter in the "home" buffer that loads tweets that are in English language only. By default, the filter creation dialog will place the focus on the field to name the filter. Currently, you can filter by word, by language, or both. In the filter by word, you can make TWBlue allow or ignore tweets with the desired word. In the filter by language, you can make the program load tweets in the languages you want, or ignore tweets written in certain languages. Once created, every filter will be saved in the session config and will be kept across application restarts.
* Manage filters: Opens up a dialogue which allows you to delete filters for the current session.
* Find a string in the currently focused buffer: Opens a dialogue where you can search for items in the current buffer.
* Mute: Mutes notifications of a particular buffer so you will not hear when new tweets arrive.
* autoread: When enabled, the screen reader or SAPI 5 Text to Speech voice (if enabled) will read the text of incoming tweets. Please note that this could get rather chatty if there are a lot of incoming tweets.
* Clear buffer: Deletes all items from the buffer.
@@ -173,6 +179,8 @@ Visually, Towards the top of the main application window, can be found a menu ba
* What's new in this version?: opens up a document with the list of changes from the current version to the earliest.
* Check for updates: every time you open the program it automatically checks for new versions. If an update is available, it will ask you if you want to download the update. If you accept, the updating process will commence. When complete, TWBlue will be restarted. This item checks for new updates without having to restart the application.
* TWBlue's website: visit our [home page](http://twblue.es) where you can find all relevant information and downloads for TWBlue and become a part of the community.
* Get soundpacks for TWBlue:
* Make a Donation: Opens a website from which you can donate to the TWBlue project. Donations are made through paypal and you don't need an account to donate.
* About TWBlue: shows the credits of the program.
### The invisible user interface
@@ -350,4 +358,4 @@ Many thanks also to the people who worked on the documentation. Initially, [Manu
------------------------------------------------------------------------
Copyright © 2013-2017. Manuel Cortéz
Copyright © 2013-2021. Manuel Cortéz

View File

@@ -1,9 +1,10 @@
wxpython
pytest
coverage
wheel
six
future
configobj
markdown
future
requests
oauthlib
requests-oauthlib
@@ -12,7 +13,6 @@ pypubsub
geopy
arrow
python-dateutil
futures
winpaths
PySocks
win_inet_pton
@@ -31,6 +31,7 @@ backports.functools_lru_cache
cx_freeze
tweepy
twitter-text-parser
mastodon.py
pyenchant
sqlitedict
cx-Logging
@@ -48,6 +49,7 @@ importlib-metadata
numpy
pillow
charset-normalizer
demoji
git+https://github.com/accessibleapps/libloader
git+https://github.com/accessibleapps/platform_utils
git+https://github.com/accessibleapps/accessible_output2

View File

@@ -14,7 +14,7 @@ SetCompress auto
SetCompressor /solid lzma
SetDatablockOptimize on
VIAddVersionKey ProductName "TWBlue"
VIAddVersionKey LegalCopyright "Copyright 2014-2021 Manuel Cortéz."
VIAddVersionKey LegalCopyright "Copyright 2014-2022 MCV Software."
VIAddVersionKey ProductVersion "0.95.0"
VIAddVersionKey FileVersion "0.95.0"
VIProductVersion "0.95.0"

View File

@@ -14,7 +14,8 @@ retweet_mode = string(default="ask")
persist_size = integer(default=0)
load_cache_in_memory=boolean(default=True)
show_screen_names = boolean(default=False)
buffer_order = list(default=list('home','mentions', 'dm', 'sent_dm', 'sent_tweets','favorites','followers','friends','blocks','muted','events'))
hide_emojis = boolean(default=False)
buffer_order = list(default=list('home','mentions', 'dm', 'sent_dm', 'sent_tweets','favorites','followers','friends','blocks','muted'))
[sound]
volume = float(default=1.0)
@@ -48,6 +49,12 @@ ocr_language = string(default="")
braille_reporting = boolean(default=True)
speech_reporting = boolean(default=True)
[templates]
tweet = string(default="$display_name, $text $image_descriptions $date. $source")
dm = string(default="$sender_display_name, $text $date")
dm_sent = string(default="Dm to $recipient_display_name, $text $date")
person = string(default="$display_name (@$screen_name). $followers followers, $following following, $tweets tweets. Joined Twitter $created_at.")
[filters]
[user-aliases]

View File

@@ -1,16 +1,14 @@
# -*- coding: utf-8 -*-
import datetime
name = 'TWBlue'
short_name='twblue'
update_url = 'https://twblue.es/updates/updates.php'
mirror_update_url = 'https://raw.githubusercontent.com/manuelcortez/TWBlue/next-gen/updates/updates.json'
authors = ["Manuel Cortéz", "José Manuel Delicado"]
authorEmail = "manuel@manuelcortez.net"
copyright = "Copyright (C) 2013-2021, Manuel cortéz."
copyright = "Copyright (C) 2013-2022, MCV Software."
description = name+" is an app designed to use Twitter simply and efficiently while using minimal system resources. This app provides access to most Twitter features."
translators = ["Manuel Cortéz (English)", "Mohammed Al Shara, Hatoun Felemban (Arabic)", "Francisco Torres (Catalan)", "Manuel cortéz (Spanish)", "Sukil Etxenike Arizaleta (Basque)", "Jani Kinnunen (finnish)", "Oreonan (Français)", "Juan Buño (Galician)", "Steffen Schultz (German)", "Zvonimir Stanečić (Croatian)", "Robert Osztolykan (Hungarian)", "Christian Leo Mameli (Italian)", "Riku (Japanese)", "Paweł Masarczyk (Polish)", "Odenilton Júnior Santos (Portuguese)", "Florian Ionașcu, Nicușor Untilă (Romanian)", "Natalia Hedlund, Valeria Kuznetsova (Russian)", "Aleksandar Đurić (Serbian)", "Burak Yüksek (Turkish)"]
url = u"https://twblue.es"
report_bugs_url = "https://github.com/manuelcortez/twblue/issues"
translators = ["Manuel Cortéz (English)", "Mohammed Al Shara, Hatoun Felemban (Arabic)", "Francisco Torres (Catalan)", "Manuel cortéz (Spanish)", "Sukil Etxenike Arizaleta (Basque)", "Jani Kinnunen (finnish)", "Corentin Bacqué-Cazenave (Français)", "Juan Buño (Galician)", "Steffen Schultz (German)", "Zvonimir Stanečić (Croatian)", "Robert Osztolykan (Hungarian)", "Christian Leo Mameli (Italian)", "Riku (Japanese)", "Paweł Masarczyk (Polish)", "Odenilton Júnior Santos (Portuguese)", "Florian Ionașcu, Nicușor Untilă (Romanian)", "Natalia Hedlund, Valeria Kuznetsova (Russian)", "Aleksandar Đurić (Serbian)", "Burak Yüksek (Turkish)"]
url = "https://twblue.es"
report_bugs_url = "https://github.com/mcvsoftware/twblue/issues"
supported_languages = []
version = "11"

View File

@@ -4,6 +4,7 @@ from validate import Validator, ValidateError
import os
import string
from logging import getLogger
from wxUI import commonMessageDialogs
log = getLogger("config_utils")
class ConfigLoadError(Exception): pass
@@ -21,6 +22,7 @@ def load_config(config_path, configspec_path=None, copy=True, *args, **kwargs):
return config
else:
log.exception("Error in config file: {0}".format(validated,))
commonMessageDialogs.invalid_configuration()
def is_blank(arg):
"Check if a line is blank."

View File

@@ -1,40 +0,0 @@
# -*- coding: utf-8 -*-
from __future__ import unicode_literals
from builtins import object
import os
import widgetUtils
import logging
from wxUI.dialogs import attach as gui
log = logging.getLogger("controller.attach")
class attach(object):
def __init__(self):
self.attachments = list()
self.dialog = gui.attachDialog()
widgetUtils.connect_event(self.dialog.photo, widgetUtils.BUTTON_PRESSED, self.upload_image)
widgetUtils.connect_event(self.dialog.remove, widgetUtils.BUTTON_PRESSED, self.remove_attachment)
self.dialog.get_response()
log.debug("Attachments controller started.")
def upload_image(self, *args, **kwargs):
image, description = self.dialog.get_image()
if image != None:
imageInfo = {"type": "photo", "file": image, "description": description}
log.debug("Image data to upload: %r" % (imageInfo,))
self.attachments.append(imageInfo)
info = [_(u"Photo"), description]
self.dialog.attachments.insert_item(False, *info)
self.dialog.remove.Enable(True)
def remove_attachment(self, *args, **kwargs):
current_item = self.dialog.attachments.get_selected()
log.debug("Removing item %d" % (current_item,))
if current_item == -1: current_item = 0
self.attachments.pop(current_item)
self.dialog.attachments.remove_item(current_item)
self.check_remove_status()
log.debug("Removed")
def check_remove_status(self):
if len(self.attachments) == 0 and self.dialog.attachments.get_count() == 0:
self.dialog.remove.Enable(False)

View File

@@ -1,3 +1,4 @@
# -*- coding: utf-8 -*-
from . import base as base
from . import twitter as twitter
from . import mastodon as mastodon

View File

@@ -125,6 +125,9 @@ class Buffer(object):
def share_item(self):
pass
def can_share(self):
pass
def destroy_status(self):
pass
@@ -136,3 +139,6 @@ class Buffer(object):
self.session.db[self.name+"_pos"]=self.buffer.list.get_selected()
except AttributeError:
pass
def view_item(self):
pass

View File

@@ -0,0 +1,5 @@
# -*- coding: utf-8 -*-
from .base import BaseBuffer
from .mentions import MentionsBuffer
from .conversations import ConversationBuffer, ConversationListBuffer
from .users import UserBuffer

View File

@@ -0,0 +1,498 @@
# -*- coding: utf-8 -*-
import time
import wx
import widgetUtils
import arrow
import webbrowser
import output
import config
import sound
import languageHandler
import logging
from audio_services import youtube_utils
from controller.buffers.base import base
from controller.mastodon import messages
from sessions.mastodon import compose, utils, templates
from mysc.thread_utils import call_threaded
from pubsub import pub
from extra import ocr
from wxUI import buffers, dialogs, commonMessageDialogs
from wxUI.dialogs.mastodon import menus
from wxUI.dialogs.mastodon import dialogs as mastodon_dialogs
log = logging.getLogger("controller.buffers.mastodon.base")
class BaseBuffer(base.Buffer):
def __init__(self, parent, function, name, sessionObject, account, sound=None, compose_func="compose_post", *args, **kwargs):
super(BaseBuffer, self).__init__(parent, function, *args, **kwargs)
log.debug("Initializing buffer %s, account %s" % (name, account,))
self.create_buffer(parent, name)
self.invisible = True
self.name = name
self.type = self.buffer.type
self.session = sessionObject
self.compose_function = getattr(compose, compose_func)
log.debug("Compose_function: %s" % (self.compose_function,))
self.account = account
self.buffer.account = account
self.bind_events()
self.sound = sound
if "-timeline" in self.name or "-followers" in self.name or "-following" in self.name:
self.finished_timeline = False
def create_buffer(self, parent, name):
self.buffer = buffers.mastodon.basePanel(parent, name)
def get_buffer_name(self):
""" Get buffer name from a set of different techniques."""
# firstly let's take the easier buffers.
basic_buffers = dict(home_timeline=_("Home"), local_timeline=_("Local"), federated_timeline=_("Federated"), mentions=_("Mentions"), bookmarks=_("Bookmarks"), direct_messages=_("Direct messages"), sent=_("Sent"), favorites=_("Favorites"), followers=_("Followers"), following=_("Following"), blocked=_("Blocked users"), muted=_("Muted users"), notifications=_("Notifications"))
if self.name in list(basic_buffers.keys()):
return basic_buffers[self.name]
# Check user timelines
elif hasattr(self, "username"):
if "-timeline" in self.name:
return _(u"{username}'s timeline").format(username=self.username,)
elif "-followers" in self.name:
return _(u"{username}'s followers").format(username=self.username,)
elif "-following" in self.name:
return _(u"{username}'s following").format(username=self.username,)
log.error("Error getting name for buffer %s" % (self.name,))
return _(u"Unknown buffer")
def post_status(self, *args, **kwargs):
title = _("Post")
caption = _("Write your post here")
post = messages.post(session=self.session, title=title, caption=caption)
response = post.message.ShowModal()
if response == wx.ID_OK:
post_data = post.get_data()
call_threaded(self.session.send_post, posts=post_data, visibility=post.get_visibility(), **kwargs)
if hasattr(post.message, "destroy"):
post.message.destroy()
def get_formatted_message(self):
return self.compose_function(self.get_item(), self.session.db, self.session.settings["general"]["relative_times"], self.session.settings["general"]["show_screen_names"])[1]
def get_message(self):
post = self.get_item()
if post == None:
return
template = self.session.settings["templates"]["post"]
t = templates.render_post(post, template, relative_times=self.session.settings["general"]["relative_times"], offset_hours=self.session.db["utc_offset"])
return t
def start_stream(self, mandatory=False, play_sound=True, avoid_autoreading=False):
current_time = time.time()
if self.execution_time == 0 or current_time-self.execution_time >= 180 or mandatory==True:
self.execution_time = current_time
log.debug("Starting stream for buffer %s, account %s and type %s" % (self.name, self.account, self.type))
log.debug("args: %s, kwargs: %s" % (self.args, self.kwargs))
count = self.session.settings["general"]["max_posts_per_call"]
min_id = None
# toDo: Implement reverse timelines properly here.
if (self.name != "favorites" and self.name != "bookmarks") and self.name in self.session.db and len(self.session.db[self.name]) > 0:
min_id = self.session.db[self.name][-1].id
try:
results = getattr(self.session.api, self.function)(min_id=min_id, limit=count, *self.args, **self.kwargs)
results.reverse()
except Exception as e:
log.exception("Error %s" % (str(e)))
return
number_of_items = self.session.order_buffer(self.name, results)
log.debug("Number of items retrieved: %d" % (number_of_items,))
if hasattr(self, "finished_timeline") and self.finished_timeline == False:
if "-timeline" in self.name:
self.username = self.session.db[self.name][0]["account"].username
self.finished_timeline = True
self.put_items_on_list(number_of_items)
if number_of_items > 0 and self.name != "sent_posts" and self.name != "sent_direct_messages" and self.sound != None and self.session.settings["sound"]["session_mute"] == False and self.name not in self.session.settings["other_buffers"]["muted_buffers"] and play_sound == True:
self.session.sound.play(self.sound)
# Autoread settings
if avoid_autoreading == False and mandatory == True and number_of_items > 0 and self.name in self.session.settings["other_buffers"]["autoread_buffers"]:
self.auto_read(number_of_items)
return number_of_items
def auto_read(self, number_of_items):
if number_of_items == 1 and self.name in self.session.settings["other_buffers"]["autoread_buffers"] and self.name not in self.session.settings["other_buffers"]["muted_buffers"] and self.session.settings["sound"]["session_mute"] == False:
if self.session.settings["general"]["reverse_timelines"] == False:
post = self.session.db[self.name][-1]
else:
post = self.session.db[self.name][0]
output.speak(_("New post in {0}").format(self.get_buffer_name()))
output.speak(" ".join(self.compose_function(post, self.session.db, self.session.settings["general"]["relative_times"], self.session.settings["general"]["show_screen_names"])))
elif number_of_items > 1 and self.name in self.session.settings["other_buffers"]["autoread_buffers"] and self.name not in self.session.settings["other_buffers"]["muted_buffers"] and self.session.settings["sound"]["session_mute"] == False:
output.speak(_("{0} new posts in {1}.").format(number_of_items, self.get_buffer_name()))
def get_more_items(self):
elements = []
if self.session.settings["general"]["reverse_timelines"] == False:
max_id = self.session.db[self.name][0].id
else:
max_id = self.session.db[self.name][-1].id
try:
items = getattr(self.session.api, self.function)(max_id=max_id, limit=self.session.settings["general"]["max_posts_per_call"], *self.args, **self.kwargs)
except Exception as e:
log.exception("Error %s" % (str(e)))
return
items_db = self.session.db[self.name]
for i in items:
if utils.find_item(i, self.session.db[self.name]) == None:
elements.append(i)
if self.session.settings["general"]["reverse_timelines"] == False:
items_db.insert(0, i)
else:
items_db.append(i)
self.session.db[self.name] = items_db
selection = self.buffer.list.get_selected()
log.debug("Retrieved %d items from cursored search in function %s." % (len(elements), self.function))
if self.session.settings["general"]["reverse_timelines"] == False:
for i in elements:
post = self.compose_function(i, self.session.db, self.session.settings["general"]["relative_times"], self.session.settings["general"]["show_screen_names"])
self.buffer.list.insert_item(True, *post)
else:
for i in items:
post = self.compose_function(i, self.session.db, self.session.settings["general"]["relative_times"], self.session.settings["general"]["show_screen_names"])
self.buffer.list.insert_item(False, *post)
self.buffer.list.select_item(selection)
output.speak(_(u"%s items retrieved") % (str(len(elements))), True)
def remove_buffer(self, force=False):
if "-timeline" in self.name:
if force == False:
dlg = commonMessageDialogs.remove_buffer()
else:
dlg = widgetUtils.YES
if dlg == widgetUtils.YES:
if self.kwargs.get("id") in self.session.settings["other_buffers"]["timelines"]:
self.session.settings["other_buffers"]["timelines"].remove(self.kwargs.get("id"))
self.session.settings.write()
if self.name in self.session.db:
self.session.db.pop(self.name)
return True
elif dlg == widgetUtils.NO:
return False
else:
output.speak(_(u"This buffer is not a timeline; it can't be deleted."), True)
return False
def put_items_on_list(self, number_of_items):
list_to_use = self.session.db[self.name]
if number_of_items == 0 and self.session.settings["general"]["persist_size"] == 0: return
log.debug("The list contains %d items " % (self.buffer.list.get_count(),))
log.debug("Putting %d items on the list" % (number_of_items,))
if self.buffer.list.get_count() == 0:
for i in list_to_use:
post = self.compose_function(i, self.session.db, self.session.settings["general"]["relative_times"], self.session.settings["general"]["show_screen_names"])
self.buffer.list.insert_item(False, *post)
self.buffer.set_position(self.session.settings["general"]["reverse_timelines"])
elif self.buffer.list.get_count() > 0 and number_of_items > 0:
if self.session.settings["general"]["reverse_timelines"] == False:
items = list_to_use[len(list_to_use)-number_of_items:]
for i in items:
post = self.compose_function(i, self.session.db, self.session.settings["general"]["relative_times"], self.session.settings["general"]["show_screen_names"])
self.buffer.list.insert_item(False, *post)
else:
items = list_to_use[0:number_of_items]
items.reverse()
for i in items:
post = self.compose_function(i, self.session.db, self.session.settings["general"]["relative_times"], self.session.settings["general"]["show_screen_names"])
self.buffer.list.insert_item(True, *post)
log.debug("Now the list contains %d items " % (self.buffer.list.get_count(),))
def add_new_item(self, item):
post = self.compose_function(item, self.session.db, self.session.settings["general"]["relative_times"], self.session.settings["general"]["show_screen_names"])
if self.session.settings["general"]["reverse_timelines"] == False:
self.buffer.list.insert_item(False, *post)
else:
self.buffer.list.insert_item(True, *post)
if self.name in self.session.settings["other_buffers"]["autoread_buffers"] and self.name not in self.session.settings["other_buffers"]["muted_buffers"] and self.session.settings["sound"]["session_mute"] == False:
output.speak(" ".join(post[:2]), speech=self.session.settings["reporting"]["speech_reporting"], braille=self.session.settings["reporting"]["braille_reporting"])
def update_item(self, item, position):
post = self.compose_function(item, self.session.db, self.session.settings["general"]["relative_times"], self.session.settings["general"]["show_screen_names"])
self.buffer.list.list.SetItem(position, 1, post[1])
def bind_events(self):
log.debug("Binding events...")
self.buffer.set_focus_function(self.onFocus)
widgetUtils.connect_event(self.buffer.list.list, widgetUtils.KEYPRESS, self.get_event)
widgetUtils.connect_event(self.buffer, widgetUtils.BUTTON_PRESSED, self.post_status, self.buffer.post)
widgetUtils.connect_event(self.buffer, widgetUtils.BUTTON_PRESSED, self.share_item, self.buffer.boost)
widgetUtils.connect_event(self.buffer, widgetUtils.BUTTON_PRESSED, self.send_message, self.buffer.dm)
widgetUtils.connect_event(self.buffer, widgetUtils.BUTTON_PRESSED, self.reply, self.buffer.reply)
widgetUtils.connect_event(self.buffer, widgetUtils.BUTTON_PRESSED, self.toggle_favorite, self.buffer.fav)
widgetUtils.connect_event(self.buffer, widgetUtils.BUTTON_PRESSED, self.toggle_bookmark, self.buffer.bookmark)
widgetUtils.connect_event(self.buffer.list.list, wx.EVT_LIST_ITEM_RIGHT_CLICK, self.show_menu)
widgetUtils.connect_event(self.buffer.list.list, wx.EVT_LIST_KEY_DOWN, self.show_menu_by_key)
def show_menu(self, ev, pos=0, *args, **kwargs):
if self.buffer.list.get_count() == 0:
return
menu = menus.base()
widgetUtils.connect_event(menu, widgetUtils.MENU, self.reply, menuitem=menu.reply)
widgetUtils.connect_event(menu, widgetUtils.MENU, self.user_actions, menuitem=menu.userActions)
widgetUtils.connect_event(menu, widgetUtils.MENU, self.share_item, menuitem=menu.boost)
widgetUtils.connect_event(menu, widgetUtils.MENU, self.fav, menuitem=menu.fav)
widgetUtils.connect_event(menu, widgetUtils.MENU, self.unfav, menuitem=menu.unfav)
widgetUtils.connect_event(menu, widgetUtils.MENU, self.url_, menuitem=menu.openUrl)
widgetUtils.connect_event(menu, widgetUtils.MENU, self.audio, menuitem=menu.play)
widgetUtils.connect_event(menu, widgetUtils.MENU, self.view, menuitem=menu.view)
widgetUtils.connect_event(menu, widgetUtils.MENU, self.copy, menuitem=menu.copy)
widgetUtils.connect_event(menu, widgetUtils.MENU, self.destroy_status, menuitem=menu.remove)
if hasattr(menu, "openInBrowser"):
widgetUtils.connect_event(menu, widgetUtils.MENU, self.open_in_browser, menuitem=menu.openInBrowser)
if pos != 0:
self.buffer.PopupMenu(menu, pos)
else:
self.buffer.PopupMenu(menu, self.buffer.list.list.GetPosition())
def view(self, *args, **kwargs):
pub.sendMessage("execute-action", action="view_item")
def copy(self, *args, **kwargs):
pub.sendMessage("execute-action", action="copy_to_clipboard")
def user_actions(self, *args, **kwargs):
pub.sendMessage("execute-action", action="follow")
def fav(self, *args, **kwargs):
pub.sendMessage("execute-action", action="add_to_favourites")
def unfav(self, *args, **kwargs):
pub.sendMessage("execute-action", action="remove_from_favourites")
def delete_item_(self, *args, **kwargs):
pub.sendMessage("execute-action", action="delete_item")
def url_(self, *args, **kwargs):
self.url()
def show_menu_by_key(self, ev):
if self.buffer.list.get_count() == 0:
return
if ev.GetKeyCode() == wx.WXK_WINDOWS_MENU:
self.show_menu(widgetUtils.MENU, pos=self.buffer.list.list.GetPosition())
def get_item(self):
index = self.buffer.list.get_selected()
if index > -1 and self.session.db.get(self.name) != None:
return self.session.db[self.name][index]
def can_share(self):
post = self.get_item()
if post.visibility == "direct":
return False
return True
def reply(self, *args):
item = self.get_item()
visibility = item.visibility
if visibility == "direct":
title = _("Conversation with {}").format(item.account.username)
caption = _("Write your message here")
else:
title = _("Reply to {}").format(item.account.username)
caption = _("Write your reply here")
if item.reblog != None:
users = ["@{} ".format(user.acct) for user in item.reblog.mentions if user.id != self.session.db["user_id"]]
if item.reblog.account.acct != item.account.acct and "@{} ".format(item.reblog.account.acct) not in users:
users.append("@{} ".format(item.reblog.account.acct))
else:
users = ["@{} ".format(user.acct) for user in item.mentions if user.id != self.session.db["user_id"]]
if "@{} ".format(item.account.acct) not in users and item.account.id != self.session.db["user_id"]:
users.insert(0, "@{} ".format(item.account.acct))
users_str = "".join(users)
post = messages.post(session=self.session, title=title, caption=caption, text=users_str)
visibility_settings = dict(public=0, unlisted=1, private=2, direct=3)
post.message.visibility.SetSelection(visibility_settings.get(visibility))
# Respect content warning settings.
if item.sensitive:
post.message.sensitive.SetValue(item.sensitive)
post.message.spoiler.ChangeValue(item.spoiler_text)
post.message.on_sensitivity_changed()
response = post.message.ShowModal()
if response == wx.ID_OK:
post_data = post.get_data()
call_threaded(self.session.send_post, reply_to=item.id, posts=post_data, visibility=post.get_visibility())
if hasattr(post.message, "destroy"):
post.message.destroy()
def send_message(self, *args, **kwargs):
item = self.get_item()
title = _("Conversation with {}").format(item.account.username)
caption = _("Write your message here")
if item.reblog != None:
users = ["@{} ".format(user.acct) for user in item.reblog.mentions if user.id != self.session.db["user_id"]]
if item.reblog.account.acct != item.account.acct and "@{} ".format(item.reblog.account.acct) not in users:
users.append("@{} ".format(item.reblog.account.acct))
else:
users = ["@{} ".format(user.acct) for user in item.mentions if user.id != self.session.db["user_id"]]
if item.account.acct not in users and item.account.id != self.session.db["user_id"]:
users.insert(0, "@{} ".format(item.account.acct))
users_str = "".join(users)
post = messages.post(session=self.session, title=title, caption=caption, text=users_str)
post.message.visibility.SetSelection(3)
if item.sensitive:
post.message.sensitive.SetValue(item.sensitive)
post.message.spoiler.ChangeValue(item.spoiler_text)
post.message.on_sensitivity_changed()
response = post.message.ShowModal()
if response == wx.ID_OK:
post_data = post.get_data()
call_threaded(self.session.send_post, posts=post_data, visibility="direct", reply_to=item.id)
if hasattr(post.message, "destroy"):
post.message.destroy()
def share_item(self, *args, **kwargs):
if self.can_share() == False:
return output.speak(_("This action is not supported on conversation posts."))
post = self.get_item()
id = post.id
if self.session.settings["general"]["boost_mode"] == "ask":
answer = mastodon_dialogs.boost_question()
if answer == True:
self._direct_boost(id)
else:
self._direct_boost(id)
def _direct_boost(self, id):
item = self.session.api_call(call_name="status_reblog", _sound="retweet_send.ogg", id=id)
def onFocus(self, *args, **kwargs):
post = self.get_item()
if self.session.settings["general"]["relative_times"] == True:
original_date = arrow.get(self.session.db[self.name][self.buffer.list.get_selected()].created_at)
ts = original_date.humanize(locale=languageHandler.getLanguage())
self.buffer.list.list.SetItem(self.buffer.list.get_selected(), 2, ts)
if self.session.settings['sound']['indicate_audio'] and utils.is_audio_or_video(post):
self.session.sound.play("audio.ogg")
if self.session.settings['sound']['indicate_img'] and utils.is_image(post):
self.session.sound.play("image.ogg")
can_share = self.can_share()
pub.sendMessage("toggleShare", shareable=can_share)
self.buffer.boost.Enable(can_share)
def audio(self, url='', *args, **kwargs):
if sound.URLPlayer.player.is_playing():
return sound.URLPlayer.stop_audio()
item = self.get_item()
if item == None:
return
urls = utils.get_media_urls(item)
if len(urls) == 1:
url=urls[0]
elif len(urls) > 1:
urls_list = dialogs.urlList.urlList()
urls_list.populate_list(urls)
if urls_list.get_response() == widgetUtils.OK:
url=urls_list.get_string()
if hasattr(urls_list, "destroy"): urls_list.destroy()
if url != '':
# try:
sound.URLPlayer.play(url, self.session.settings["sound"]["volume"])
# except:
# log.error("Exception while executing audio method.")
def url(self, url='', announce=True, *args, **kwargs):
if url == '':
post = self.get_item()
if post.reblog != None:
urls = utils.find_urls(post.reblog)
else:
urls = utils.find_urls(post)
if len(urls) == 1:
url=urls[0]
elif len(urls) > 1:
urls_list = dialogs.urlList.urlList()
urls_list.populate_list(urls)
if urls_list.get_response() == widgetUtils.OK:
url=urls_list.get_string()
if hasattr(urls_list, "destroy"): urls_list.destroy()
if url != '':
if announce:
output.speak(_(u"Opening URL..."), True)
webbrowser.open_new_tab(url)
def clear_list(self):
dlg = commonMessageDialogs.clear_list()
if dlg == widgetUtils.YES:
self.session.db[self.name] = []
self.buffer.list.clear()
def destroy_status(self, *args, **kwargs):
index = self.buffer.list.get_selected()
item = self.session.db[self.name][index]
if item.account.id != self.session.db["user_id"] or item.reblog != None:
output.speak(_("You can delete only your own posts."))
return
answer = mastodon_dialogs.delete_post_dialog()
if answer == True:
items = self.session.db[self.name]
try:
self.session.api.status_delete(id=item.id)
items.pop(index)
self.buffer.list.remove_item(index)
except Exception as e:
self.session.sound.play("error.ogg")
self.session.db[self.name] = items
def user_details(self):
item = self.get_item()
pass
def get_item_url(self):
post = self.get_item()
if post.reblog != None:
return post.reblog.url
return post.url
def open_in_browser(self, *args, **kwargs):
url = self.get_item_url()
output.speak(_("Opening item in web browser..."))
webbrowser.open(url)
def add_to_favorites(self):
item = self.get_item()
if item.reblog != None:
item = item.reblog
call_threaded(self.session.api_call, call_name="status_favourite", preexec_message=_("Adding to favorites..."), _sound="favourite.ogg", id=item.id)
def remove_from_favorites(self):
item = self.get_item()
if item.reblog != None:
item = item.reblog
call_threaded(self.session.api_call, call_name="status_unfavourite", preexec_message=_("Removing from favorites..."), _sound="favourite.ogg", id=item.id)
def toggle_favorite(self, *args, **kwargs):
item = self.get_item()
if item.reblog != None:
item = item.reblog
item = self.session.api.status(item.id)
if item.favourited == False:
call_threaded(self.session.api_call, call_name="status_favourite", preexec_message=_("Adding to favorites..."), _sound="favourite.ogg", id=item.id)
else:
call_threaded(self.session.api_call, call_name="status_unfavourite", preexec_message=_("Removing from favorites..."), _sound="favourite.ogg", id=item.id)
def toggle_bookmark(self, *args, **kwargs):
item = self.get_item()
if item.reblog != None:
item = item.reblog
item = self.session.api.status(item.id)
if item.bookmarked == False:
call_threaded(self.session.api_call, call_name="status_bookmark", preexec_message=_("Adding to bookmarks..."), _sound="favourite.ogg", id=item.id)
else:
call_threaded(self.session.api_call, call_name="status_unbookmark", preexec_message=_("Removing from bookmarks..."), _sound="favourite.ogg", id=item.id)
def view_item(self):
post = self.get_item()
# Update object so we can retrieve newer stats
post = self.session.api.status(id=post.id)
print(post)
msg = messages.viewPost(post, offset_hours=self.session.db["utc_offset"], item_url=self.get_item_url())
def ocr_image(self):
post = self.get_item()
media_list = []
pass

View File

@@ -0,0 +1,241 @@
# -*- coding: utf-8 -*-
import time
import logging
import wx
import widgetUtils
import output
from controller.mastodon import messages
from controller.buffers.mastodon.base import BaseBuffer
from mysc.thread_utils import call_threaded
from sessions.mastodon import utils, templates
from wxUI import buffers, commonMessageDialogs
log = logging.getLogger("controller.buffers.mastodon.conversations")
class ConversationListBuffer(BaseBuffer):
def create_buffer(self, parent, name):
self.buffer = buffers.mastodon.conversationListPanel(parent, name)
def get_item(self):
index = self.buffer.list.get_selected()
if index > -1 and self.session.db.get(self.name) != None and len(self.session.db[self.name]) > index:
return self.session.db[self.name][index]["last_status"]
def get_conversation(self):
index = self.buffer.list.get_selected()
if index > -1 and self.session.db.get(self.name) != None:
return self.session.db[self.name][index]
def get_formatted_message(self):
return self.compose_function(self.get_conversation(), self.session.db, self.session.settings["general"]["relative_times"], self.session.settings["general"]["show_screen_names"])[1]
def get_message(self):
conversation = self.get_conversation()
if conversation == None:
return
template = self.session.settings["templates"]["conversation"]
post_template = self.session.settings["templates"]["post"]
t = templates.render_conversation(conversation=conversation, template=template, post_template=post_template, relative_times=self.session.settings["general"]["relative_times"], offset_hours=self.session.db["utc_offset"])
return t
def start_stream(self, mandatory=False, play_sound=True, avoid_autoreading=False):
current_time = time.time()
if self.execution_time == 0 or current_time-self.execution_time >= 180 or mandatory==True:
self.execution_time = current_time
log.debug("Starting stream for buffer %s, account %s and type %s" % (self.name, self.account, self.type))
log.debug("args: %s, kwargs: %s" % (self.args, self.kwargs))
count = self.session.settings["general"]["max_posts_per_call"]
min_id = None
# toDo: Implement reverse timelines properly here.
# if (self.name != "favorites" and self.name != "bookmarks") and self.name in self.session.db and len(self.session.db[self.name]) > 0:
# min_id = self.session.db[self.name][-1].id
try:
results = getattr(self.session.api, self.function)(min_id=min_id, limit=count, *self.args, **self.kwargs)
results.reverse()
except Exception as e:
log.exception("Error %s" % (str(e)))
return
new_position, number_of_items = self.order_buffer(results)
log.debug("Number of items retrieved: %d" % (number_of_items,))
self.put_items_on_list(number_of_items)
if new_position > -1:
self.buffer.list.select_item(new_position)
if number_of_items > 0 and self.name != "sent_posts" and self.name != "sent_direct_messages" and self.sound != None and self.session.settings["sound"]["session_mute"] == False and self.name not in self.session.settings["other_buffers"]["muted_buffers"] and play_sound == True:
self.session.sound.play(self.sound)
# Autoread settings
if avoid_autoreading == False and mandatory == True and number_of_items > 0 and self.name in self.session.settings["other_buffers"]["autoread_buffers"]:
self.auto_read(number_of_items)
return number_of_items
def get_more_items(self):
elements = []
if self.session.settings["general"]["reverse_timelines"] == False:
max_id = self.session.db[self.name][0].last_status.id
else:
max_id = self.session.db[self.name][-1].last_status.id
try:
items = getattr(self.session.api, self.function)(max_id=max_id, limit=self.session.settings["general"]["max_posts_per_call"], *self.args, **self.kwargs)
except Exception as e:
log.exception("Error %s" % (str(e)))
return
items_db = self.session.db[self.name]
for i in items:
if utils.find_item(i, self.session.db[self.name]) == None:
elements.append(i)
if self.session.settings["general"]["reverse_timelines"] == False:
items_db.insert(0, i)
else:
items_db.append(i)
self.session.db[self.name] = items_db
selection = self.buffer.list.get_selected()
log.debug("Retrieved %d items from cursored search in function %s." % (len(elements), self.function))
if self.session.settings["general"]["reverse_timelines"] == False:
for i in elements:
conversation = self.compose_function(i, self.session.db, self.session.settings["general"]["relative_times"], self.session.settings["general"]["show_screen_names"])
self.buffer.list.insert_item(True, *conversation)
else:
for i in items:
conversation = self.compose_function(i, self.session.db, self.session.settings["general"]["relative_times"], self.session.settings["general"]["show_screen_names"])
self.buffer.list.insert_item(False, *conversation)
self.buffer.list.select_item(selection)
output.speak(_(u"%s items retrieved") % (str(len(elements))), True)
def get_item_position(self, conversation):
for i in range(len(self.session.db[self.name])):
if self.session.db[self.name][i].id == conversation.id:
return i
def order_buffer(self, data):
num = 0
focus_object = None
if self.session.db.get(self.name) == None:
self.session.db[self.name] = []
objects = self.session.db[self.name]
for i in data:
position = self.get_item_position(i)
if position != None:
conversation = self.session.db[self.name][position]
if conversation.last_status.id != i.last_status.id:
focus_object = i
objects.pop(position)
self.buffer.list.remove_item(position)
if self.session.settings["general"]["reverse_timelines"] == False:
objects.append(i)
else:
objects.insert(0, i)
num = num+1
else:
if self.session.settings["general"]["reverse_timelines"] == False:
objects.append(i)
else:
objects.insert(0, i)
num = num+1
self.session.db[self.name] = objects
if focus_object == None:
return (-1, num)
new_position = self.get_item_position(focus_object)
if new_position != None:
return (new_position, num)
return (-1, num)
def bind_events(self):
log.debug("Binding events...")
self.buffer.set_focus_function(self.onFocus)
widgetUtils.connect_event(self.buffer.list.list, widgetUtils.KEYPRESS, self.get_event)
widgetUtils.connect_event(self.buffer, widgetUtils.BUTTON_PRESSED, self.post_status, self.buffer.post)
widgetUtils.connect_event(self.buffer, widgetUtils.BUTTON_PRESSED, self.reply, self.buffer.reply)
widgetUtils.connect_event(self.buffer.list.list, wx.EVT_LIST_ITEM_RIGHT_CLICK, self.show_menu)
widgetUtils.connect_event(self.buffer.list.list, wx.EVT_LIST_KEY_DOWN, self.show_menu_by_key)
def fav(self):
pass
def unfav(self):
pass
def can_share(self):
return False
def send_message(self):
return self.reply()
def onFocus(self, *args, **kwargs):
post = self.get_item()
if self.session.settings['sound']['indicate_audio'] and utils.is_audio_or_video(post):
self.session.sound.play("audio.ogg")
if self.session.settings['sound']['indicate_img'] and utils.is_image(post):
self.session.sound.play("image.ogg")
def destroy_status(self):
pass
def reply(self, *args):
item = self.get_item()
conversation = self.get_conversation()
visibility = item.visibility
title = _("Reply to conversation with {}").format(conversation.accounts[0].username)
caption = _("Write your message here")
users = ["@{} ".format(user.acct) for user in conversation.accounts]
users_str = "".join(users)
post = messages.post(session=self.session, title=title, caption=caption, text=users_str)
visibility_settings = dict(public=0, unlisted=1, private=2, direct=3)
post.message.visibility.SetSelection(visibility_settings.get(visibility))
if item.sensitive:
post.message.sensitive.SetValue(item.sensitive)
post.message.spoiler.ChangeValue(item.spoiler_text)
post.message.on_sensitivity_changed()
response = post.message.ShowModal()
if response == wx.ID_OK:
post_data = post.get_data()
call_threaded(self.session.send_post, reply_to=item.id, posts=post_data, visibility=visibility)
if hasattr(post.message, "destroy"):
post.message.destroy()
class ConversationBuffer(BaseBuffer):
def __init__(self, post, *args, **kwargs):
self.post = post
super(ConversationBuffer, self).__init__(*args, **kwargs)
def start_stream(self, mandatory=False, play_sound=True, avoid_autoreading=False):
current_time = time.time()
if self.execution_time == 0 or current_time-self.execution_time >= 180 or mandatory==True:
self.execution_time = current_time
log.debug("Starting stream for buffer %s, account %s and type %s" % (self.name, self.account, self.type))
log.debug("args: %s, kwargs: %s" % (self.args, self.kwargs))
self.post = self.session.api.status(id=self.post.id)
# toDo: Implement reverse timelines properly here.
try:
results = []
items = getattr(self.session.api, self.function)(*self.args, **self.kwargs)
[results.append(item) for item in items.ancestors]
results.append(self.post)
[results.append(item) for item in items.descendants]
except Exception as e:
log.exception("Error %s" % (str(e)))
return
number_of_items = self.session.order_buffer(self.name, results)
log.debug("Number of items retrieved: %d" % (number_of_items,))
self.put_items_on_list(number_of_items)
if number_of_items > 0 and self.name != "sent_posts" and self.name != "sent_direct_messages" and self.sound != None and self.session.settings["sound"]["session_mute"] == False and self.name not in self.session.settings["other_buffers"]["muted_buffers"] and play_sound == True:
self.session.sound.play(self.sound)
# Autoread settings
if avoid_autoreading == False and mandatory == True and number_of_items > 0 and self.name in self.session.settings["other_buffers"]["autoread_buffers"]:
self.auto_read(number_of_items)
return number_of_items
def get_more_items(self):
output.speak(_(u"This action is not supported for this buffer"), True)
def remove_buffer(self, force=False):
if force == False:
dlg = commonMessageDialogs.remove_buffer()
else:
dlg = widgetUtils.YES
if dlg == widgetUtils.YES:
if self.name in self.session.db:
self.session.db.pop(self.name)
return True
elif dlg == widgetUtils.NO:
return False

View File

@@ -0,0 +1,71 @@
# -*- coding: utf-8 -*-
import time
import logging
from controller.buffers.mastodon.base import BaseBuffer
from sessions.mastodon import utils
log = logging.getLogger("controller.buffers.mastodon.mentions")
class MentionsBuffer(BaseBuffer):
def start_stream(self, mandatory=False, play_sound=True, avoid_autoreading=False):
current_time = time.time()
if self.execution_time == 0 or current_time-self.execution_time >= 180 or mandatory==True:
self.execution_time = current_time
log.debug("Starting stream for buffer %s, account %s and type %s" % (self.name, self.account, self.type))
log.debug("args: %s, kwargs: %s" % (self.args, self.kwargs))
count = self.session.settings["general"]["max_posts_per_call"]
min_id = None
# toDo: Implement reverse timelines properly here.
# if self.name != "favorites" and self.name in self.session.db and len(self.session.db[self.name]) > 0:
# min_id = self.session.db[self.name][-1].id
try:
items = getattr(self.session.api, self.function)(min_id=min_id, limit=count, exclude_types=["follow", "favourite", "reblog", "poll", "follow_request"], *self.args, **self.kwargs)
items.reverse()
results = [item.status for item in items if item.get("status") and item.type == "mention"]
except Exception as e:
log.exception("Error %s" % (str(e)))
return
number_of_items = self.session.order_buffer(self.name, results)
log.debug("Number of items retrieved: %d" % (number_of_items,))
self.put_items_on_list(number_of_items)
if number_of_items > 0 and self.name != "sent_posts" and self.name != "sent_direct_messages" and self.sound != None and self.session.settings["sound"]["session_mute"] == False and self.name not in self.session.settings["other_buffers"]["muted_buffers"] and play_sound == True:
self.session.sound.play(self.sound)
# Autoread settings
if avoid_autoreading == False and mandatory == True and number_of_items > 0 and self.name in self.session.settings["other_buffers"]["autoread_buffers"]:
self.auto_read(number_of_items)
return number_of_items
def get_more_items(self):
elements = []
if self.session.settings["general"]["reverse_timelines"] == False:
max_id = self.session.db[self.name][0].id
else:
max_id = self.session.db[self.name][-1].id
try:
items = getattr(self.session.api, self.function)(max_id=max_id, limit=self.session.settings["general"]["max_posts_per_call"], exclude_types=["follow", "favourite", "reblog", "poll", "follow_request"], *self.args, **self.kwargs)
items = [item.status for item in items if item.get("status") and item.type == "mention"]
except Exception as e:
log.exception("Error %s" % (str(e)))
return
items_db = self.session.db[self.name]
for i in items:
if utils.find_item(i, self.session.db[self.name]) == None:
elements.append(i)
if self.session.settings["general"]["reverse_timelines"] == False:
items_db.insert(0, i)
else:
items_db.append(i)
self.session.db[self.name] = items_db
selection = self.buffer.list.get_selected()
log.debug("Retrieved %d items from cursored search in function %s." % (len(elements), self.function))
if self.session.settings["general"]["reverse_timelines"] == False:
for i in elements:
post = self.compose_function(i, self.session.db, self.session.settings["general"]["relative_times"], self.session.settings["general"]["show_screen_names"])
self.buffer.list.insert_item(True, *post)
else:
for i in items:
post = self.compose_function(i, self.session.db, self.session.settings["general"]["relative_times"], self.session.settings["general"]["show_screen_names"])
self.buffer.list.insert_item(False, *post)
self.buffer.list.select_item(selection)
output.speak(_(u"%s items retrieved") % (str(len(elements))), True)

View File

@@ -0,0 +1,202 @@
# -*- coding: utf-8 -*-
import time
import logging
import wx
import widgetUtils
import output
from mysc.thread_utils import call_threaded
from controller.buffers.mastodon.base import BaseBuffer
from controller.mastodon import messages
from sessions.mastodon import templates, utils
from wxUI import buffers, commonMessageDialogs
log = logging.getLogger("controller.buffers.mastodon.conversations")
class UserBuffer(BaseBuffer):
def create_buffer(self, parent, name):
self.buffer = buffers.mastodon.userPanel(parent, name)
def get_message(self):
user = self.get_item()
if user == None:
return
template = self.session.settings["templates"]["person"]
t = templates.render_user(user=user, template=template, relative_times=self.session.settings["general"]["relative_times"], offset_hours=self.session.db["utc_offset"])
return t
def bind_events(self):
widgetUtils.connect_event(self.buffer.list.list, widgetUtils.KEYPRESS, self.get_event)
widgetUtils.connect_event(self.buffer, widgetUtils.BUTTON_PRESSED, self.post_status, self.buffer.post)
widgetUtils.connect_event(self.buffer, widgetUtils.BUTTON_PRESSED, self.send_message, self.buffer.message)
widgetUtils.connect_event(self.buffer, widgetUtils.BUTTON_PRESSED, self.user_actions, self.buffer.actions)
widgetUtils.connect_event(self.buffer.list.list, wx.EVT_LIST_ITEM_RIGHT_CLICK, self.show_menu)
widgetUtils.connect_event(self.buffer.list.list, wx.EVT_LIST_KEY_DOWN, self.show_menu_by_key)
def fav(self):
pass
def unfav(self):
pass
def can_share(self):
return False
def reply(self, *args, **kwargs):
return self.send_message()
def send_message(self, *args, **kwargs):
item = self.get_item()
title = _("New conversation with {}").format(item.username)
caption = _("Write your message here")
users_str = "@{} ".format(item.acct)
post = messages.post(session=self.session, title=title, caption=caption, text=users_str)
post.message.visibility.SetSelection(3)
response = post.message.ShowModal()
if response == wx.ID_OK:
post_data = post.get_data()
call_threaded(self.session.send_post, posts=post_data, visibility="direct")
if hasattr(post.message, "destroy"):
post.message.destroy()
def audio(self):
pass
def url(self):
pass
def destroy_status(self):
pass
def start_stream(self, mandatory=False, play_sound=True, avoid_autoreading=False):
current_time = time.time()
if self.execution_time == 0 or current_time-self.execution_time >= 180 or mandatory==True:
self.execution_time = current_time
log.debug("Starting stream for buffer %s, account %s and type %s" % (self.name, self.account, self.type))
log.debug("args: %s, kwargs: %s" % (self.args, self.kwargs))
count = self.session.settings["general"]["max_posts_per_call"]
# toDo: Implement reverse timelines properly here.
try:
results = getattr(self.session.api, self.function)(limit=count, *self.args, **self.kwargs)
if hasattr(results, "_pagination_next") and self.name not in self.session.db["pagination_info"]:
self.session.db["pagination_info"][self.name] = results._pagination_next
results.reverse()
except Exception as e:
log.exception("Error %s" % (str(e)))
return
number_of_items = self.session.order_buffer(self.name, results)
log.debug("Number of items retrieved: %d" % (number_of_items,))
if hasattr(self, "finished_timeline") and self.finished_timeline == False:
if "-followers" in self.name or "-following" in self.name:
self.username = self.session.api.account(id=self.kwargs.get("id")).username
self.finished_timeline = True
self.put_items_on_list(number_of_items)
if number_of_items > 0 and self.name != "sent_posts" and self.name != "sent_direct_messages" and self.sound != None and self.session.settings["sound"]["session_mute"] == False and self.name not in self.session.settings["other_buffers"]["muted_buffers"] and play_sound == True:
self.session.sound.play(self.sound)
# Autoread settings
if avoid_autoreading == False and mandatory == True and number_of_items > 0 and self.name in self.session.settings["other_buffers"]["autoread_buffers"]:
self.auto_read(number_of_items)
return number_of_items
def get_more_items(self):
elements = []
pagination_info = self.session.db["pagination_info"].get(self.name)
if pagination_info == None:
output.speak(_("There are no more items in this buffer."))
return
try:
items = self.session.api.fetch_next(pagination_info)
if hasattr(items, "_pagination_next"):
self.session.db["pagination_info"][self.name] = items._pagination_next
except Exception as e:
log.exception("Error %s" % (str(e)))
return
items_db = self.session.db[self.name]
for i in items:
if utils.find_item(i, self.session.db[self.name]) == None:
elements.append(i)
if self.session.settings["general"]["reverse_timelines"] == False:
items_db.insert(0, i)
else:
items_db.append(i)
self.session.db[self.name] = items_db
selection = self.buffer.list.get_selected()
log.debug("Retrieved %d items from cursored search in function %s." % (len(elements), self.function))
if self.session.settings["general"]["reverse_timelines"] == False:
for i in elements:
post = self.compose_function(i, self.session.db, self.session.settings["general"]["relative_times"], self.session.settings["general"]["show_screen_names"])
self.buffer.list.insert_item(True, *post)
else:
for i in items:
post = self.compose_function(i, self.session.db, self.session.settings["general"]["relative_times"], self.session.settings["general"]["show_screen_names"])
self.buffer.list.insert_item(False, *post)
self.buffer.list.select_item(selection)
output.speak(_(u"%s items retrieved") % (str(len(elements))), True)
def get_item_url(self):
item = self.get_item()
return item.url
def user_details(self):
item = self.get_item()
pass
def add_to_favorites(self):
pass
def remove_from_favorites(self):
pass
def toggle_favorite(self):
pass
def view_item(self):
item = self.get_item()
print(item)
def ocr_image(self):
pass
def remove_buffer(self, force=False):
if "-followers" in self.name:
if force == False:
dlg = commonMessageDialogs.remove_buffer()
else:
dlg = widgetUtils.YES
if dlg == widgetUtils.YES:
if self.kwargs.get("id") in self.session.settings["other_buffers"]["followers_timelines"]:
self.session.settings["other_buffers"]["followers_timelines"].remove(self.kwargs.get("id"))
self.session.settings.write()
if self.name in self.session.db:
self.session.db.pop(self.name)
return True
elif dlg == widgetUtils.NO:
return False
elif "-following" in self.name:
if force == False:
dlg = commonMessageDialogs.remove_buffer()
else:
dlg = widgetUtils.YES
if dlg == widgetUtils.YES:
if self.kwargs.get("id") in self.session.settings["other_buffers"]["following_timelines"]:
self.session.settings["other_buffers"]["following_timelines"].remove(self.kwargs.get("id"))
self.session.settings.write()
if self.name in self.session.db:
self.session.db.pop(self.name)
return True
elif dlg == widgetUtils.NO:
return False
elif "-searchUser" in self.name:
if force == False:
dlg = commonMessageDialogs.remove_buffer()
else:
dlg = widgetUtils.YES
if dlg == widgetUtils.YES:
if self.name in self.session.db:
self.session.db.pop(self.name)
return True
elif dlg == widgetUtils.NO:
return False
else:
output.speak(_(u"This buffer is not a timeline; it can't be deleted."), True)
return False

View File

@@ -1,14 +1,6 @@
# -*- coding: utf-8 -*-
import time
import platform
if platform.system() == "Windows":
import wx
from wxUI import buffers, dialogs, commonMessageDialogs, menus
from controller import user
elif platform.system() == "Linux":
from gi.repository import Gtk
from gtkUI import buffers, dialogs, commonMessageDialogs
from controller import messages
import wx
import widgetUtils
import arrow
import webbrowser
@@ -19,12 +11,15 @@ import languageHandler
import logging
from audio_services import youtube_utils
from controller.buffers.base import base
from sessions.twitter import compose, utils, reduce
from sessions.twitter import compose, utils, reduce, templates
from mysc.thread_utils import call_threaded
from tweepy.errors import TweepyException
from tweepy.cursor import Cursor
from pubsub import pub
from extra import ocr
from sessions.twitter.long_tweets import twishort, tweets
from wxUI import buffers, dialogs, commonMessageDialogs, menus
from controller.twitter import user, messages
log = logging.getLogger("controller.buffers")
@@ -40,9 +35,9 @@ class BaseBuffer(base.Buffer):
super(BaseBuffer, self).__init__(parent, function, *args, **kwargs)
log.debug("Initializing buffer %s, account %s" % (name, account,))
if bufferType != None:
self.buffer = getattr(buffers, bufferType)(parent, name)
self.buffer = getattr(buffers.twitter, bufferType)(parent, name)
else:
self.buffer = buffers.basePanel(parent, name)
self.buffer = buffers.twitter.basePanel(parent, name)
self.invisible = True
self.name = name
self.type = self.buffer.type
@@ -84,42 +79,15 @@ class BaseBuffer(base.Buffer):
return _(u"Unknown buffer")
def post_status(self, *args, **kwargs):
item = None
title = _(u"Tweet")
caption = _(u"Write the tweet here")
title = _("Tweet")
caption = _("Write the tweet here")
tweet = messages.tweet(self.session, title, caption, "")
if tweet.message.get_response() == widgetUtils.OK:
if config.app["app-settings"]["remember_mention_and_longtweet"]:
config.app["app-settings"]["longtweet"] = tweet.message.long_tweet.GetValue()
config.app.write()
text = tweet.message.get_text()
if len(text) > 280 and tweet.message.get("long_tweet") == True:
if not hasattr(tweet, "attachments"):
text = twishort.create_tweet(self.session.settings["twitter"]["user_key"], self.session.settings["twitter"]["user_secret"], text)
else:
text = twishort.create_tweet(self.session.settings["twitter"]["user_key"], self.session.settings["twitter"]["user_secret"], text, 1)
if not hasattr(tweet, "attachments") or len(tweet.attachments) == 0:
item = self.session.api_call(call_name="update_status", status=text, _sound="tweet_send.ogg", tweet_mode="extended")
else:
call_threaded(self.post_with_media, text=text, attachments=tweet.attachments)
# We will no longer will reuse the sent item from here as Streaming API should give us the new and correct item.
# but in case we'd need it, just uncomment the following couple of lines and make sure we reduce the item correctly.
# if item != None:
# pub.sendMessage("sent-tweet", data=item, user=self.session.db["user_name"])
if hasattr(tweet.message, "destroy"): tweet.message.destroy()
self.session.settings.write()
def post_with_media(self, text, attachments):
media_ids = []
for i in attachments:
img = self.session.twitter.media_upload(i["file"])
self.session.twitter.create_media_metadata(media_id=img.media_id, alt_text=i["description"])
media_ids.append(img.media_id)
item = self.session.twitter.update_status(status=text, media_ids=media_ids)
# We will no longer will reuse the sent item from here as Streaming API should give us the new and correct item.
# but in case we'd need it, just uncomment the following couple of lines and make sure we reduce the item correctly.
# if item != None:
# pub.sendMessage("sent-tweet", data=item, user=self.session.db["user_name"])
response = tweet.message.ShowModal()
if response == wx.ID_OK:
tweet_data = tweet.get_tweet_data()
call_threaded(self.session.send_tweet, *tweet_data)
if hasattr(tweet.message, "destroy"):
tweet.message.destroy()
def get_formatted_message(self):
if self.type == "dm" or self.name == "direct_messages":
@@ -127,8 +95,10 @@ class BaseBuffer(base.Buffer):
return self.get_message()
def get_message(self):
template = self.session.settings["templates"]["tweet"]
tweet = self.get_right_tweet()
return " ".join(self.compose_function(tweet, self.session.db, self.session.settings["general"]["relative_times"], self.session.settings["general"]["show_screen_names"], self.session))
t = templates.render_tweet(tweet, template, self.session, relative_times=self.session.settings["general"]["relative_times"], offset_seconds=self.session.db["utc_offset"])
return t
def get_full_tweet(self):
tweet = self.get_right_tweet()
@@ -167,7 +137,7 @@ class BaseBuffer(base.Buffer):
log.debug("Starting stream for buffer %s, account %s and type %s" % (self.name, self.account, self.type))
log.debug("args: %s, kwargs: %s" % (self.args, self.kwargs))
if self.name != "direct_messages":
val = self.session.call_paged(self.function, *self.args, **self.kwargs)
val = self.session.call_paged(self.function, self.name, *self.args, **self.kwargs)
else:
# 50 results are allowed per API call, so let's assume max value can be 50.
# reference: https://developer.twitter.com/en/docs/twitter-api/v1/direct-messages/sending-and-receiving/api-reference/list-events
@@ -199,9 +169,9 @@ class BaseBuffer(base.Buffer):
self.put_items_on_list(number_of_items)
if hasattr(self, "finished_timeline") and self.finished_timeline == False:
if "-timeline" in self.name:
self.username = val[0].user.screen_name
self.username = self.session.get_user(self.kwargs.get("user_id")).screen_name
elif "-favorite" in self.name:
self.username = self.session.api_call("get_user", **self.kwargs).screen_name
self.username = self.session.get_user(self.kwargs.get("user_id")).screen_name
self.finished_timeline = True
if number_of_items > 0 and self.name != "sent_tweets" and self.name != "sent_direct_messages" and self.sound != None and self.session.settings["sound"]["session_mute"] == False and self.name not in self.session.settings["other_buffers"]["muted_buffers"] and play_sound == True:
self.session.sound.play(self.sound)
@@ -334,9 +304,6 @@ class BaseBuffer(base.Buffer):
self.buffer.list.insert_item(True, *tweet)
if self.name in self.session.settings["other_buffers"]["autoread_buffers"] and self.name not in self.session.settings["other_buffers"]["muted_buffers"] and self.session.settings["sound"]["session_mute"] == False:
output.speak(" ".join(tweet[:2]), speech=self.session.settings["reporting"]["speech_reporting"], braille=self.session.settings["reporting"]["braille_reporting"])
#Improve performance on Windows
# if platform.system() == "Windows":
# call_threaded(utils.is_audio,item)
def bind_events(self):
log.debug("Binding events...")
@@ -347,7 +314,6 @@ class BaseBuffer(base.Buffer):
widgetUtils.connect_event(self.buffer, widgetUtils.BUTTON_PRESSED, self.share_item, self.buffer.retweet)
widgetUtils.connect_event(self.buffer, widgetUtils.BUTTON_PRESSED, self.send_message, self.buffer.dm)
widgetUtils.connect_event(self.buffer, widgetUtils.BUTTON_PRESSED, self.reply, self.buffer.reply)
# Replace for the correct way in other platforms.
widgetUtils.connect_event(self.buffer.list.list, wx.EVT_LIST_ITEM_RIGHT_CLICK, self.show_menu)
widgetUtils.connect_event(self.buffer.list.list, wx.EVT_LIST_KEY_DOWN, self.show_menu_by_key)
@@ -416,13 +382,18 @@ class BaseBuffer(base.Buffer):
tweet = self.session.db[self.name][self.buffer.list.get_selected()]
return tweet
def can_share(self):
tweet = self.get_right_tweet()
user = self.session.get_user(tweet.user)
is_protected = user.protected
return is_protected==False
@_tweets_exist
def reply(self, *args, **kwargs):
tweet = self.get_right_tweet()
user = self.session.get_user(tweet.user)
screen_name = user.screen_name
id = tweet.id
twishort_enabled = hasattr(tweet, "twishort")
users = utils.get_all_mentioned(tweet, self.session.db, field="screen_name")
ids = utils.get_all_mentioned(tweet, self.session.db, field="id")
# Build the window title
@@ -430,38 +401,14 @@ class BaseBuffer(base.Buffer):
title=_("Reply to {arg0}").format(arg0=screen_name)
else:
title=_("Reply")
message = messages.reply(self.session, title, _(u"Reply to %s") % (screen_name,), "", users=users, ids=ids)
if message.message.get_response() == widgetUtils.OK:
message = messages.reply(self.session, title, _("Reply to %s") % (screen_name,), "", users=users, ids=ids)
if message.message.ShowModal() == widgetUtils.OK:
if config.app["app-settings"]["remember_mention_and_longtweet"]:
config.app["app-settings"]["longtweet"] = message.message.long_tweet.GetValue()
if len(users) > 0:
config.app["app-settings"]["mention_all"] = message.message.mentionAll.GetValue()
config.app["app-settings"]["mention_all"] = message.message.mention_all.GetValue()
config.app.write()
params = {"_sound": "reply_send.ogg", "in_reply_to_status_id": id, "tweet_mode": "extended"}
text = message.message.get_text()
if twishort_enabled == False:
excluded_ids = message.get_ids()
params["exclude_reply_user_ids"] =excluded_ids
params["auto_populate_reply_metadata"] =True
else:
mentioned_people = message.get_people()
text = "@"+screen_name+" "+mentioned_people+u" "+text
if len(text) > 280 and message.message.get("long_tweet") == True:
if message.image == None:
text = twishort.create_tweet(self.session.settings["twitter"]["user_key"], self.session.settings["twitter"]["user_secret"], text)
else:
text = twishort.create_tweet(self.session.settings["twitter"]["user_key"], self.session.settings["twitter"]["user_secret"], text, 1)
params["status"] = text
if message.image == None:
params["call_name"] = "update_status"
else:
params["call_name"] = "update_status_with_media"
params["media"] = message.file
item = self.session.api_call(**params)
# We will no longer will reuse the sent item from here as Streaming API should give us the new and correct item.
# but in case we'd need it, just uncomment the following couple of lines and make sure we reduce the item correctly.
# if item != None:
# pub.sendMessage("sent-tweet", data=item, user=self.session.db["user_name"])
tweet_data = dict(text=message.message.text.GetValue(), attachments=message.attachments, poll_options=message.poll_options, poll_period=message.poll_period)
call_threaded(self.session.reply, in_reply_to_status_id=id, text=message.message.text.GetValue(), attachments=message.attachments, exclude_reply_user_ids=message.get_ids())
if hasattr(message.message, "destroy"): message.message.destroy()
self.session.settings.write()
@@ -477,25 +424,23 @@ class BaseBuffer(base.Buffer):
else:
screen_name = self.session.get_user(tweet.user).screen_name
users = utils.get_all_users(tweet, self.session)
dm = messages.dm(self.session, _(u"Direct message to %s") % (screen_name,), _(u"New direct message"), users)
if dm.message.get_response() == widgetUtils.OK:
screen_name = dm.message.get("cb")
dm = messages.dm(self.session, _("Direct message to %s") % (screen_name,), _("New direct message"), users)
if dm.message.ShowModal() == widgetUtils.OK:
screen_name = dm.message.cb.GetValue()
user = self.session.get_user_by_screen_name(screen_name)
recipient_id = user
text = dm.message.get_text()
val = self.session.api_call(call_name="send_direct_message", recipient_id=recipient_id, text=text)
if val != None:
sent_dms = self.session.db["sent_direct_messages"]
if self.session.settings["general"]["reverse_timelines"] == False:
sent_dms.append(val)
text = dm.message.text.GetValue()
if len(dm.attachments) > 0:
attachment = dm.attachments[0]
else:
sent_dms.insert(0, val)
self.session.db["sent_direct_messages"] = sent_dms
pub.sendMessage("sent-dm", data=val, user=self.session.db["user_name"])
attachment = None
call_threaded(self.session.direct_message, text=text, recipient=recipient_id, attachment=attachment)
if hasattr(dm.message, "destroy"): dm.message.destroy()
@_tweets_exist
def share_item(self, *args, **kwargs):
if self.can_share() == False:
return output.speak(_("This action is not supported on protected accounts."))
tweet = self.get_right_tweet()
id = tweet.id
if self.session.settings["general"]["retweet_mode"] == "ask":
@@ -509,44 +454,24 @@ class BaseBuffer(base.Buffer):
else:
self._retweet_with_comment(tweet, id)
def _retweet_with_comment(self, tweet, id, comment=''):
# If quoting a retweet, let's quote the original tweet instead the retweet.
def _retweet_with_comment(self, tweet, id):
if hasattr(tweet, "retweeted_status"):
tweet = tweet.retweeted_status
if hasattr(tweet, "full_text"):
comments = tweet.full_text
else:
comments = tweet.text
retweet = messages.tweet(self.session, _(u"Quote"), _(u"Add your comment to the tweet"), u"“@%s: %s" % (self.session.get_user(tweet.user).screen_name, comments), max=256, messageType="retweet")
if comment != '':
retweet.message.set_text(comment)
if retweet.message.get_response() == widgetUtils.OK:
text = retweet.message.get_text()
text = text+" https://twitter.com/{0}/status/{1}".format(self.session.get_user(tweet.user).screen_name, id)
if retweet.image == None:
# We will no longer will reuse the sent item from here as Streaming API should give us the new and correct item.
# but in case we'd need it, just uncomment the following couple of lines and make sure we reduce the item correctly.
item = self.session.api_call(call_name="update_status", _sound="retweet_send.ogg", status=text, in_reply_to_status_id=id, tweet_mode="extended")
# if item != None:
# new_item = self.session.twitter.get_status(id=item.id, include_ext_alt_text=True, tweet_mode="extended")
# pub.sendMessage("sent-tweet", data=new_item, user=self.session.db["user_name"])
else:
call_threaded(self.session.api_call, call_name="update_status", _sound="retweet_send.ogg", status=text, media=retweet.image)
if hasattr(retweet.message, "destroy"): retweet.message.destroy()
retweet = messages.tweet(session=self.session, title=_("Quote"), caption=_("Add your comment to the tweet"), max=256, thread_mode=False)
if retweet.message.ShowModal() == widgetUtils.OK:
text = retweet.message.text.GetValue()
tweet_data = dict(text=text, attachments=retweet.attachments, poll_period=retweet.poll_period, poll_options=retweet.poll_options)
tweet_data.update(quote_tweet_id=id)
call_threaded(self.session.send_tweet, *[tweet_data])
if hasattr(retweet.message, "destroy"):
retweet.message.Destroy()
def _direct_retweet(self, id):
item = self.session.api_call(call_name="retweet", _sound="retweet_send.ogg", id=id)
# We will no longer will reuse the sent item from here as Streaming API should give us the new and correct item.
# but in case we'd need it, just uncomment the following couple of lines and make sure we reduce the item correctly.
# if item != None:
# Retweets are returned as non-extended tweets, so let's get the object as extended
# just before sending the event message. See https://github.com/manuelcortez/TWBlue/issues/253
# item = self.session.twitter.get_status(id=item.id, include_ext_alt_text=True, tweet_mode="extended")
# pub.sendMessage("sent-tweet", data=item, user=self.session.db["user_name"])
def onFocus(self, *args, **kwargs):
tweet = self.get_tweet()
if platform.system() == "Windows" and self.session.settings["general"]["relative_times"] == True:
if self.session.settings["general"]["relative_times"] == True:
# fix this:
original_date = arrow.get(self.session.db[self.name][self.buffer.list.get_selected()].created_at, locale="en")
ts = original_date.humanize(locale=languageHandler.getLanguage())
@@ -557,6 +482,9 @@ class BaseBuffer(base.Buffer):
self.session.sound.play("geo.ogg")
if self.session.settings['sound']['indicate_img'] and utils.is_media(tweet):
self.session.sound.play("image.ogg")
can_share = self.can_share()
pub.sendMessage("toggleShare", shareable=can_share)
self.buffer.retweet.Enable(can_share)
def audio(self, url='', *args, **kwargs):
if sound.URLPlayer.player.is_playing():
@@ -653,3 +581,83 @@ class BaseBuffer(base.Buffer):
url = self.get_item_url()
output.speak(_(u"Opening item in web browser..."))
webbrowser.open(url)
def add_to_favorites(self):
id = self.get_tweet().id
call_threaded(self.session.api_call, call_name="create_favorite", _sound="favourite.ogg", id=id)
def remove_from_favorites(self):
id = self.get_tweet().id
call_threaded(self.session.api_call, call_name="destroy_favorite", id=id)
def toggle_favorite(self):
id = self.get_tweet().id
tweet = self.session.twitter.get_status(id=id, include_ext_alt_text=True, tweet_mode="extended")
if tweet.favorited == False:
call_threaded(self.session.api_call, call_name="create_favorite", _sound="favourite.ogg", id=id)
else:
call_threaded(self.session.api_call, call_name="destroy_favorite", id=id)
def view_item(self):
if self.type == "dm" or self.name == "direct_messages":
non_tweet = self.get_formatted_message()
item = self.get_right_tweet()
original_date = arrow.get(int(item.created_timestamp))
date = original_date.shift(seconds=self.session.db["utc_offset"]).format(_(u"MMM D, YYYY. H:m"), locale=languageHandler.getLanguage())
msg = messages.viewTweet(non_tweet, [], False, date=date)
else:
tweet, tweetsList = self.get_full_tweet()
msg = messages.viewTweet(tweet, tweetsList, utc_offset=self.session.db["utc_offset"], item_url=self.get_item_url())
def reverse_geocode(self, geocoder):
try:
tweet = self.get_tweet()
if tweet.coordinates != None:
x = tweet.coordinates["coordinates"][0]
y = tweet.coordinates["coordinates"][1]
address = geocoder.reverse_geocode(y, x, language = languageHandler.curLang)
return address
else:
output.speak(_("There are no coordinates in this tweet"))
# except GeocoderError:
# output.speak(_(u"There are no results for the coordinates in this tweet"))
except ValueError:
output.speak(_(u"Error decoding coordinates. Try again later."))
except KeyError:
pass
except AttributeError:
pass
def ocr_image(self):
tweet = self.get_tweet()
media_list = []
if hasattr(tweet, "entities") and tweet.entities.get("media") != None:
[media_list.append(i) for i in tweet.entities["media"] if i not in media_list]
elif hasattr(tweet, "retweeted_status") and tweet.retweeted_status.get("media") != None:
[media_list.append(i) for i in tweet.retweeted_status.entities["media"] if i not in media_list]
elif hasattr(tweet, "quoted_status") and tweet.quoted_status.entities.get("media") != None:
[media_list.append(i) for i in tweet.quoted_status.entities["media"] if i not in media_list]
if len(media_list) > 1:
image_list = [_(u"Picture {0}").format(i,) for i in range(0, len(media_list))]
dialog = dialogs.urlList.urlList(title=_(u"Select the picture"))
if dialog.get_response() == widgetUtils.OK:
img = media_list[dialog.get_item()]
else:
return
elif len(media_list) == 1:
img = media_list[0]
else:
output.speak(_(u"Invalid buffer"))
return
if self.session.settings["mysc"]["ocr_language"] != "":
ocr_lang = self.session.settings["mysc"]["ocr_language"]
else:
ocr_lang = ocr.OCRSpace.short_langs.index(tweet.lang)
ocr_lang = ocr.OCRSpace.OcrLangs[ocr_lang]
api = ocr.OCRSpace.OCRSpaceAPI()
try:
text = api.OCR_URL(img["media_url"], lang=ocr_lang)
except ocr.OCRSpace.APIError as er:
output.speak(_(u"Unable to extract text"))
return
msg = messages.viewTweet(text["ParsedText"], [], False)

View File

@@ -1,5 +1,4 @@
# -*- coding: utf-8 -*-
import platform
import widgetUtils
import arrow
import webbrowser
@@ -7,11 +6,12 @@ import output
import config
import languageHandler
import logging
from controller import messages
from sessions.twitter import compose, utils
from sessions.twitter import compose, utils, templates
from mysc.thread_utils import call_threaded
from tweepy.errors import TweepyException
from pubsub import pub
from wxUI import commonMessageDialogs
from controller.twitter import messages
from . import base
log = logging.getLogger("controller.buffers.twitter.dmBuffer")
@@ -69,7 +69,7 @@ class DirectMessagesBuffer(base.BaseBuffer):
self.session.db["sent_direct_messages"] = sent_dms
user_ids = [item.message_create["sender_id"] for item in items]
self.session.save_users(user_ids)
pub.sendMessage("more-sent-dms", data=sent, account=self.session.db["user_name"])
pub.sendMessage("twitter.more_sent_dms", data=sent, account=self.session.db["user_name"])
selected = self.buffer.list.get_selected()
if self.session.settings["general"]["reverse_timelines"] == True:
for i in received:
@@ -89,22 +89,16 @@ class DirectMessagesBuffer(base.BaseBuffer):
def reply(self, *args, **kwargs):
tweet = self.get_right_tweet()
screen_name = self.session.get_user(tweet.message_create["sender_id"]).screen_name
message = messages.reply(self.session, _(u"Mention"), _(u"Mention to %s") % (screen_name,), "@%s " % (screen_name,), [screen_name,])
if message.message.get_response() == widgetUtils.OK:
if config.app["app-settings"]["remember_mention_and_longtweet"]:
config.app["app-settings"]["longtweet"] = message.message.long_tweet.GetValue()
config.app.write()
if message.image == None:
item = self.session.api_call(call_name="update_status", _sound="reply_send.ogg", status=message.message.get_text(), tweet_mode="extended")
if item != None:
pub.sendMessage("sent-tweet", data=item, user=self.session.db["user_name"])
else:
call_threaded(self.session.api_call, call_name="update_status_with_media", _sound="reply_send.ogg", status=message.message.get_text(), media=message.file)
if hasattr(message.message, "destroy"): message.message.destroy()
message = messages.reply(session=self.session, title=_("Mention"), caption=_("Mention to %s") % (screen_name,), text="@%s " % (screen_name,), thread_mode=False, users=[screen_name,])
if message.message.ShowModal() == widgetUtils.OK:
tweet_data = message.get_tweet_data()
call_threaded(self.session.send_tweet, tweet_data)
if hasattr(message.message, "destroy"):
message.message.destroy()
def onFocus(self, *args, **kwargs):
tweet = self.get_tweet()
if platform.system() == "Windows" and self.session.settings["general"]["relative_times"] == True:
if self.session.settings["general"]["relative_times"] == True:
# fix this:
original_date = arrow.get(int(tweet.created_timestamp))
ts = original_date.humanize(locale=languageHandler.getLanguage())
@@ -134,6 +128,12 @@ class DirectMessagesBuffer(base.BaseBuffer):
def open_in_browser(self, *args, **kwargs):
output.speak(_(u"This action is not supported in the buffer yet."))
def get_message(self):
template = self.session.settings["templates"]["dm"]
dm = self.get_right_tweet()
t = templates.render_dm(dm, template, self.session, relative_times=self.session.settings["general"]["relative_times"], offset_seconds=self.session.db["utc_offset"])
return t
class SentDirectMessagesBuffer(DirectMessagesBuffer):
def __init__(self, *args, **kwargs):
@@ -156,3 +156,16 @@ class SentDirectMessagesBuffer(DirectMessagesBuffer):
for i in items:
tweet = self.compose_function(i, self.session.db, self.session.settings["general"]["relative_times"], self.session.settings["general"]["show_screen_names"], self.session)
self.buffer.list.insert_item(False, *tweet)
def get_message(self):
template = self.session.settings["templates"]["dm_sent"]
dm = self.get_right_tweet()
t = templates.render_dm(dm, template, self.session, relative_times=self.session.settings["general"]["relative_times"], offset_seconds=self.session.db["utc_offset"])
return t
def view_item(self):
non_tweet = self.get_formatted_message()
item = self.get_right_tweet()
original_date = arrow.get(int(item.created_timestamp))
date = original_date.shift(seconds=self.session.db["utc_offset"]).format(_(u"MMM D, YYYY. H:m"), locale=languageHandler.getLanguage())
msg = messages.viewTweet(non_tweet, [], False, date=date)

View File

@@ -1,13 +1,8 @@
# -*- coding: utf-8 -*-
import platform
if platform.system() == "Windows":
from wxUI import dialogs, commonMessageDialogs
elif platform.system() == "Linux":
from gi.repository import Gtk
from gtkUI import dialogs, commonMessageDialogs
import widgetUtils
import logging
from tweepy.cursor import Cursor
from wxUI import dialogs, commonMessageDialogs
from . import base
log = logging.getLogger("controller.buffers.twitter.listBuffer")

View File

@@ -1,13 +1,5 @@
# -*- coding: utf-8 -*-
import time
import platform
if platform.system() == "Windows":
from wxUI import commonMessageDialogs, menus
from controller import user
elif platform.system() == "Linux":
from gi.repository import Gtk
from gtkUI import dialogs, commonMessageDialogs
from controller import messages
import widgetUtils
import webbrowser
import output
@@ -16,7 +8,9 @@ import logging
from mysc.thread_utils import call_threaded
from tweepy.errors import TweepyException
from pubsub import pub
from sessions.twitter import compose
from controller.twitter import user, messages
from sessions.twitter import compose, templates
from wxUI import commonMessageDialogs, menus
from . import base
log = logging.getLogger("controller.buffers.twitter.peopleBuffer")
@@ -84,7 +78,10 @@ class PeopleBuffer(base.BaseBuffer):
pass
def get_message(self):
return " ".join(self.compose_function(self.get_tweet(), self.session.db, self.session.settings["general"]["relative_times"], self.session.settings["general"]["show_screen_names"], self.session))
template = self.session.settings["templates"]["person"]
user = self.get_right_tweet()
t = templates.render_person(user, template, self.session, relative_times=True, offset_seconds=self.session.db["utc_offset"])
return t
def delete_item(self): pass
@@ -92,18 +89,12 @@ class PeopleBuffer(base.BaseBuffer):
def reply(self, *args, **kwargs):
tweet = self.get_right_tweet()
screen_name = tweet.screen_name
message = messages.reply(self.session, _(u"Mention"), _(u"Mention to %s") % (screen_name,), "@%s " % (screen_name,), [screen_name,])
if message.message.get_response() == widgetUtils.OK:
if config.app["app-settings"]["remember_mention_and_longtweet"]:
config.app["app-settings"]["longtweet"] = message.message.long_tweet.GetValue()
config.app.write()
if message.image == None:
item = self.session.api_call(call_name="update_status", _sound="reply_send.ogg", status=message.message.get_text(), tweet_mode="extended")
if item != None:
pub.sendMessage("sent-tweet", data=item, user=self.session.db["user_name"])
else:
call_threaded(self.session.api_call, call_name="update_status_with_media", _sound="reply_send.ogg", status=message.message.get_text(), media=message.file)
if hasattr(message.message, "destroy"): message.message.destroy()
message = messages.tweet(session=self.session, title=_("Mention"), caption=_("Mention to %s") % (screen_name,), text="@%s " % (screen_name,), thread_mode=False)
if message.message.ShowModal() == widgetUtils.OK:
tweet_data = message.get_tweet_data()
call_threaded(self.session.send_tweet, *tweet_data)
if hasattr(message.message, "destroy"):
message.message.destroy()
def start_stream(self, mandatory=False, play_sound=True, avoid_autoreading=False):
# starts stream every 3 minutes.
@@ -256,3 +247,8 @@ class PeopleBuffer(base.BaseBuffer):
tweet = self.get_tweet()
url = "https://twitter.com/{screen_name}".format(screen_name=tweet.screen_name)
return url
def view_item(self):
item_url = self.get_item_url()
non_tweet = self.get_formatted_message()
msg = messages.viewTweet(non_tweet, [], False, item_url=item_url)

View File

@@ -1,15 +1,10 @@
# -*- coding: utf-8 -*-
import time
import platform
import locale
if platform.system() == "Windows":
from wxUI import commonMessageDialogs
elif platform.system() == "Linux":
from gi.repository import Gtk
from gtkUI import commonMessageDialogs
import widgetUtils
import logging
from tweepy.errors import TweepyException
from wxUI import commonMessageDialogs
from . import base, people
log = logging.getLogger("controller.buffers.twitter.searchBuffer")
@@ -64,12 +59,20 @@ class SearchPeopleBuffer(people.PeopleBuffer):
return False
class ConversationBuffer(SearchBuffer):
last_thread_id = None
last_reply_id = None
def __init__(self, tweet, *args, **kwargs):
self.tweet = tweet
super(ConversationBuffer, self).__init__(*args, **kwargs)
def start_stream(self, start=False, mandatory=False, play_sound=True, avoid_autoreading=False):
current_time = time.time()
if self.execution_time == 0 or current_time-self.execution_time >= 180 or mandatory == True:
self.execution_time = current_time
log.debug("Retrieving conversation. Last thread ID is {}, last reply ID is {}".format(self.last_thread_id, self.last_reply_id))
results = self.get_replies(self.tweet)
log.debug("Retrieved {} items before filters.".format(len(results)))
number_of_items = self.session.order_buffer(self.name, results)
log.debug("Number of items retrieved: %d" % (number_of_items,))
self.put_items_on_list(number_of_items)
@@ -94,30 +97,91 @@ class ConversationBuffer(SearchBuffer):
def get_replies(self, tweet):
""" Try to retrieve the whole conversation for the passed object by using a mix between calls to API V1.1 and V2 """
results = []
# If the tweet that starts the conversation is a reply to something else, let's try to get the parent tweet first.
if hasattr(self, "in_reply_to_status_id") and self.tweet.in_reply_to_status_id != None:
# firstly we would try to retrieve the whole thread, then we will get replies.
# this makes us to waste two search API calls, but there's no better option to retrieve the whole thread including replies, unfortunately.
thread_results = []
reply_results = []
# try to fetch conversation_id of the tweet initiating the buffer.
try:
tweet2 = self.session.twitter_v2.get_tweet(id=self.tweet.in_reply_to_status_id, user_auth=True, tweet_fields=["conversation_id"])
results.append(tweet2)
tweet = self.session.twitter_v2.get_tweet(id=self.tweet.id, user_auth=True, tweet_fields=["conversation_id", "author_id"])
thread_results.append(tweet.data)
except TweepyException as e:
log.exception("There was an error attempting to retrieve a parent tweet for the conversation for {}".format(self.name))
# Now, try to fetch the tweet initiating the conversation in V2 so we can get conversation_id
log.exception("Error attempting to retrieve tweet conversation ID")
thread_results.append(self.tweet)
# Return earlier cause we can't do anything if we cannot fetch the object from twitter.
return thread_results
# If tweet contains a conversation_id param, let's retrieve the original tweet which started the conversation so we will have the whole reference for later.
if hasattr(tweet.data, "conversation_id") and tweet.data.conversation_id != None:
conversation_id = tweet.data.conversation_id
original_tweet = self.session.twitter_v2.get_tweet(id=tweet.data.conversation_id, user_auth=True, tweet_fields=["conversation_id", "author_id"])
thread_results.insert(0, original_tweet.data)
else:
conversation_id = tweet.data.id
# find all tweets replying to the original thread only. Those tweets are sent by the same author who originally posted the first tweet.
try:
tweet = self.session.twitter_v2.get_tweet(id=self.tweet.id, user_auth=True, tweet_fields=["conversation_id"])
results.append(tweet.data)
term = "conversation_id:{}".format(tweet.data.conversation_id)
tweets = self.session.twitter_v2.search_recent_tweets(term, user_auth=True, max_results=98)
if tweets.data != None:
results.extend(tweets.data)
term = "conversation_id:{} from:{} to:{}".format(conversation_id, original_tweet.data.author_id, original_tweet.data.author_id)
thread_tweets = self.session.twitter_v2.search_recent_tweets(term, user_auth=True, max_results=98, since_id=self.last_thread_id, tweet_fields=["in_reply_to_user_id", "author_id", "conversation_id"])
if thread_tweets.data != None:
thread_results.extend(thread_tweets.data)
# Search only replies to conversation_id.
term = "conversation_id:{}".format(conversation_id, original_tweet.data.author_id)
reply_tweets = self.session.twitter_v2.search_recent_tweets(term, user_auth=True, max_results=50, since_id=self.last_reply_id, tweet_fields=["in_reply_to_user_id", "author_id", "conversation_id"])
if reply_tweets.data != None:
reply_results.extend(reply_tweets.data)
except TweepyException as e:
log.exception("There was an error when attempting to retrieve the whole conversation for buffer {}".format(self.buffer.name))
new_results = []
ids = [tweet.id for tweet in results]
# convert v2 tweets in normal, V1.1 tweets so we don't have to deal with those kind of objects in our infrastructure.
# ToDo: Remove this last step once we support natively all objects fetched via Twitter API V2.
results = []
ids = [tweet.id for tweet in thread_results]
if len(ids) > 0:
try:
results = self.session.twitter.lookup_statuses(ids, include_ext_alt_text=True, tweet_mode="extended")
results.sort(key=lambda x: x.id)
thread_results = self.session.twitter.lookup_statuses(ids, include_ext_alt_text=True, tweet_mode="extended")
thread_results.sort(key=lambda x: x.id)
self.last_thread_id = thread_results[-1].id
results.extend(thread_results)
except TweepyException as e:
log.exception("There was an error attempting to retrieve tweets for Twitter API V1.1, in conversation buffer {}".format(self.name))
return []
ids = [tweet.id for tweet in reply_results]
if len(ids) > 0:
try:
reply_results = self.session.twitter.lookup_statuses(ids, include_ext_alt_text=True, tweet_mode="extended")
reply_results.sort(key=lambda x: x.id)
self.last_reply_id = reply_results[-1].id
results.extend(reply_results)
except TweepyException as e:
log.exception("There was an error attempting to retrieve tweets for Twitter API V1.1, in conversation buffer {}".format(self.name))
results.sort(key=lambda x: x.id)
return results
def get_replies_v1(self, tweet):
try:
tweet = self.session.twitter.get_status(id=tweet.id, tweet_mode="extended")
except:
log.exception("Error getting tweet for making a conversation buffer.")
return []
results = []
results.append(tweet)
if hasattr(tweet, "in_reply_to_status_id") and tweet.in_reply_to_status_id != None:
while tweet.in_reply_to_status_id != None:
original_tweet = self.session.twitter.get_status(id=tweet.in_reply_to_status_id, tweet_mode="extended")
results.insert(0, original_tweet)
tweet = original_tweet
try:
term = "from:{} to:{}".format(tweet.user.screen_name, tweet.user.screen_name)
thread_tweets = self.session.twitter.search_tweets(term, count=100, since_id=tweet.id, tweet_mode="extended")
results.extend(thread_tweets)
except TweepyException as e:
log.exception("There was an error when attempting to retrieve the whole conversation for buffer {}".format(self.buffer.name))
try:
term = "to:{}".format(tweet.user.screen_name)
reply_tweets = self.session.twitter.search_tweets(term, count=100, since_id=tweet.id, tweet_mode="extended")
ids = [t.id for t in results]
reply_tweets = [t for t in reply_tweets if hasattr(t, "in_reply_to_status_id") and t.in_reply_to_status_id in ids]
results.extend(reply_tweets)
except TweepyException as e:
log.exception("There was an error when attempting to retrieve the whole conversation for buffer {}".format(self.buffer.name))
results.sort(key=lambda x: x.id)
return results

Some files were not shown because too many files have changed in this diff Show More