Tkabber contrib

Check-in [f8c41e41d4]
Login

Many hyperlinks are disabled.
Use anonymous login to enable hyperlinks.

Overview
Comment:Juick plugin (tkabber-0.11.1 branch): * Fix URL for open Juick tags. * Change "open in browser" message. * Update context menu labels and Russian translations.
Downloads: Tarball | ZIP archive | SQL archive
Timelines: family | ancestors | descendants | both | plugins-0.11.1
Files: files | file ages | folders
SHA1:f8c41e41d4bf880cfd009144bf43935744d85b46
User & Date: toktonada 2014-02-01 18:12:48
Context
2014-04-27
04:57
Juick plugin (tkabber-0.11.1 branch): * Add support for markdown-style links. check-in: cace7a6531 user: toktonada tags: plugins-0.11.1
2014-02-01
18:12
Juick plugin (tkabber-0.11.1 branch): * Fix URL for open Juick tags. * Change "open in browser" message. * Update context menu labels and Russian translations. check-in: f8c41e41d4 user: toktonada tags: plugins-0.11.1
2013-11-17
22:39
Juick plugin (tkabber-0.11.1 branch): Remove forgotten puts. check-in: 6160b601c4 user: toktonada tags: plugins-0.11.1
Changes
Hide Diffs Unified Diffs Ignore Whitespace Patch

Changes to juick/juick.tcl.

451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466


467






468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
...
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566

    if {[set idx [lsearch -glob $tags JUICK-*]] >= 0} {
        set thing [string range [lindex $tags $idx] 6 end]
    }

    if {$thing eq ""} return

    $m add command -label [::msgcat::mc \
        "\[J\] Copy thing to clipboard."] \
        -command [list [namespace current]::copy_thing $chatwin $thing]

    $m add command -label [::msgcat::mc \
        "\[J\] Open thing in browser."] \
        -command [list [namespace current]::browse_thing $chatwin $thing]

    if {[regexp {#\d+$} $thing]} {


        $m add command -label [::msgcat::mc \






            "\[J\] Subscribe to $thing replies."] \
            -command [list [namespace current]::send_to_juick \
            $chatwin "S $thing"]

        $m add command -label [::msgcat::mc \
            "\[J\] Unsubscribe from $thing replies."] \
            -command [list [namespace current]::send_to_juick \
            $chatwin "U $thing"]

        $m add command -label [::msgcat::mc \
            "\[J\] Open thread in new tab."] \
            -command [list [namespace current]::get_juick_thread \
            $chatwin $thing]
    }
}

proc send_to_juick {w body} {
    variable options
    set cw [join [lrange [split $w .] 0 end-1] .]
    set chatid [chat::winid_to_chatid $cw]
................................................................................
          regsub -- "/" [string range $thing 1 end] "#" jurl
          browseurl http://juick.com/$jurl
          }
        {^@} {
          browseurl http://juick.com/[string range $thing 1 end]
          }
        {^\*} {
          browseurl http://juick.com/last?tag=[string range $thing 1 end]
          }
    }
}

# See commented code in juick_commands_comps.
#variable commands {HELP NICK LOGIN "S " "U " ON OFF "D " "BL " "WL " "PM " VCARD PING INVITE}
variable commands {HELP NICK LOGIN S U ON OFF D BL WL PM CARD PING INVITE}







|
|



|



>
>

>
>
>
>
>
>
|




|


<
<
<
<
<







 







|







451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483





484
485
486
487
488
489
490
...
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569

    if {[set idx [lsearch -glob $tags JUICK-*]] >= 0} {
        set thing [string range [lindex $tags $idx] 6 end]
    }

    if {$thing eq ""} return

    $m add command -label [format [::msgcat::mc \
        "\[J\] Copy %s to clipboard"] $thing] \
        -command [list [namespace current]::copy_thing $chatwin $thing]

    $m add command -label [::msgcat::mc \
        "\[J\] Open in browser"]\
        -command [list [namespace current]::browse_thing $chatwin $thing]

    if {[regexp {#\d+$} $thing]} {
# Currently not implemented.
if {0} {
        $m add command -label [::msgcat::mc \
            "\[J\] Open in new tab"] \
            -command [list [namespace current]::get_juick_thread \
            $chatwin $thing]
}

        $m add command -label [::msgcat::mc \
            "\[J\] Subscribe"] \
            -command [list [namespace current]::send_to_juick \
            $chatwin "S $thing"]

        $m add command -label [::msgcat::mc \
            "\[J\] Unsubscribe"] \
            -command [list [namespace current]::send_to_juick \
            $chatwin "U $thing"]





    }
}

proc send_to_juick {w body} {
    variable options
    set cw [join [lrange [split $w .] 0 end-1] .]
    set chatid [chat::winid_to_chatid $cw]
................................................................................
          regsub -- "/" [string range $thing 1 end] "#" jurl
          browseurl http://juick.com/$jurl
          }
        {^@} {
          browseurl http://juick.com/[string range $thing 1 end]
          }
        {^\*} {
          browseurl http://juick.com/tag/[string range $thing 1 end]
          }
    }
}

# See commented code in juick_commands_comps.
#variable commands {HELP NICK LOGIN "S " "U " ON OFF "D " "BL " "WL " "PM " VCARD PING INVITE}
variable commands {HELP NICK LOGIN S U ON OFF D BL WL PM CARD PING INVITE}

Changes to juick/msgs/ru.msg.

1






2
3


4


5


6

7

::msgcat::mcset ru "\[J\] Copy thing to clipboard." "\[J\] Скопировать сущность в буфер обмена."






::msgcat::mcset ru "Whether the Juick plugin is loaded." "Загружено ли расширение для удобной работы с Juick."
::msgcat::mcset ru "\[J\] Open thing in browser." "\[J\] Открыть сущность в браузере."


::msgcat::mcset ru "Juick settings." "Параметры расширения для удобной работы с Juick"


::msgcat::mcset ru "Main Juick JID. This used for forwarding things from other chats." "Главный JID Juick'а. Используется для перенаправления сущностей из других чатов."


::msgcat::mcset ru "Indicate as personal message only private messages and replies to you." "Отмечать как персональные только приватные и адресованные вам сообщения."

::msgcat::mcset ru "Your Juick nickname determines at roster receiving, so after enable option you need to reconnecting." "Ваш псевдоним на Juick определяется при получении ростера, поэтому для работы опции после её включения требуется переподключение."

|
>
>
>
>
>
>
|
<
>
>
|
>
>
|
>
>
|
>
|
>
1
2
3
4
5
6
7
8

9
10
11
12
13
14
15
16
17
18
19
20
::msgcat::mcset ru "\[J\] Copy %s to clipboard" "\[J\] Скопировать %s в буфер обмена"
::msgcat::mcset ru "\[J\] Open in browser"      "\[J\] Открыть в браузере"
::msgcat::mcset ru "\[J\] Open in new tab"      "\[J\] Открыть в новой вкладке"
::msgcat::mcset ru "\[J\] Subscribe"            "\[J\] Подписаться"
::msgcat::mcset ru "\[J\] Unsubscribe"          "\[J\] Отписаться"

::msgcat::mcset ru "Whether the Juick plugin is loaded" \
"Загружено ли расширение для удобной работы с Juick"


::msgcat::mcset ru "Juick settings." \
"Параметры расширения для удобной работы с Juick."

::msgcat::mcset ru "Main Juick JID. This used for forwarding things from other chats." \
"Главный JID Juick'а. Используется для перенаправления сущностей из других чатов."

::msgcat::mcset ru "Indicate as personal message only private messages and replies to you." \
"Отмечать как персональные только приватные и адресованные вам сообщения."

::msgcat::mcset ru "Your Juick nickname determines at roster receiving, so after enable option you need to reconnecting." \
"Ваш псевдоним на Juick определяется при получении ростера, поэтому для работы опции после её включения требуется переподключение."