Mike Gelfand
b7a8bd45b7
Reformat affected code after recent changes
2020-08-18 20:31:06 +03:00
Mike Gelfand
ff8d0dbf3b
Switch from UNUSED macro to TR_UNUSED macro
...
Since there is no way to mark parameters as [potentially] unused in
standard C and when using MSVC compiler, use the widely accepted
cast-to-void approach instead.
2020-08-18 14:19:55 +03:00
Nicholas Guriev
05a2e15b00
i18n: translate "Ratio:" string in compact view ( #1354 )
...
Use already available translation from gettext.
Co-authored-by: Charles Kerr <charles@charleskerr.com>
2020-07-27 13:51:31 -05:00
Akatsuki
f6030b1d79
gtk: fix window width ( #1069 )
...
GTK window width cannot be smaller than the longest torrent title
Source: https://trac.transmissionbt.com/ticket/6128
Co-authored-by: Charles Kerr <ckerr@github.com>
2020-04-24 15:15:57 -05:00
Charles Kerr
b0e33117c5
Fix some gtk warnings ( #1038 )
...
* fix gtk deprecation warning: gtk_misc_set_alignment
* fix gtk deprecation warning: gtk_alignment_new
* fix gtk deprecation warning: gtk_tree_view_set_rules_hint
* fix gtk deprecation warning: gtk_image_new_from_stock
* fixup! fix gtk deprecation warning: gtk_alignment_new
* fix gtk deprecation warning: gtk_dialog_set_alternative_button_order
* fix gtk deprecation warning: gtk_show_uri
* fix gtk deprecation warning: gtk_widget_set_margin_left
* fix gtk deprecation warning: gtk_button_set_alignment
* fix gtk deprecation warning: g_type_class_add_private
* fix gtk deprecation warning: gtk_menu_popup
* fix gtk deprecation warning: gtk_misc_set_padding
* chore: uncrustify
* fix: silence G_TYPE_INSTANCE_GET_PRIVATE warning
Deprecaed starting in glib 2.58
* chore: uncrustify
2019-11-06 13:09:27 -06:00
Mike Gelfand
a3e4919385
Introduce `tr_str_is_empty` to relay intent better
2019-07-13 12:00:06 +03:00
Mike Gelfand
5693e59256
Define each identifier in a dedicated statement
...
* MISRA C++:2008, 8-0-1 - An init-declarator-list or a member-declarator-list
shall consist of a single init-declarator or member-declarator respectively
* CERT, DCL52-J. - Do not declare more than one variable per declaration
* CERT, DCL04-C. - Do not declare more than one variable per declaration
2019-03-17 09:15:35 +03:00
Mike Gelfand
82df3a87f4
Update to Uncrustify 0.68.1
...
Tweak a few rules in the process. Now all code in cli, daemon, gtk,
libtransmission, qt, and utils is properly formatted with no manual
intervention.
2019-02-15 09:21:48 +03:00
Mike Gelfand
e1d53855f4
Avoid declaring multiple variables on the same line
2017-05-01 18:46:41 +03:00
Mike Gelfand
a762c770f2
Make conditional expressions explicitly boolean
2017-04-30 19:26:01 +03:00
Mike Gelfand
4f9d9ad92b
Code style change leftovers
...
For some reason, GTK client wasn't fully processed. All the rest of changes
are mostly in comments.
2017-04-21 10:40:57 +03:00
Mike Gelfand
dadffa2c0f
Align type qualifiers to the right (code style)
...
This way all the qualifiers (`const`, `volatile`, `mutable`) are grouped
together, e.g. `T const* const x` vs. `const T* const x`. Also helps reading
types right-to-left, e.g. "constant pointer to constant T" vs. "constant
pointer to T which is constant".
2017-04-20 19:53:20 +03:00
Mike Gelfand
d7930984ef
Adjust uncrustify config, reformat all but Mac client
...
There're places where manual intervention is still required as uncrustify
is not ideal (unfortunately), but at least one may rely on it to do the
right thing most of the time (e.g. when sending in a patch).
The style itself is quite different from what we had before but making it
uniform across all the codebase is the key. I also hope that it'll make the
code more readable (YMMV) and less sensitive to further changes.
2017-04-20 10:01:22 +03:00
Mike Gelfand
2248d3670f
Get rid of $Id$ SVN keywords in source files
2016-09-02 23:10:15 +03:00
Jordan Lee
02cff80c2d
Copyedit the license's revised text: (1) remove unnecessary repitition use of the word 'license' from the top of the header and source files (2) add the standard 'we hope it's useful, but no warranty' clause to COPYING (3) make explicit that linking OpenSSL is allowed (see https://people.gnome.org/~markmc/openssl-and-the-gpl.html for background) (4) sync the Qt and GTK+ clients' license popups with COPYING's revised text
2014-01-21 03:10:30 +00:00
Jordan Lee
4b9626bb83
Licensing changes:
...
1. add the option the code to be used under GPLv2 or GPLv3; previously only GPLv2 was allowed
2. add the "proxy option" as described in GPLv3 so we can add future licenses without having to bulk-edit everything again :)
3. remove the awkward "exception for MIT code in Mac client" clause; it was unnecessary and confusing.
2014-01-19 01:09:44 +00:00
Jordan Lee
4904b923fb
(trunk) restore copyright year as suggested in email by rms
2014-01-18 20:56:57 +00:00
Jordan Lee
28fe36f1f8
#include limits.h where we use it, and don't where we don't
2013-08-24 17:53:45 +00:00
Jordan Lee
20fe66bccf
more experimentation with the shortTransferString
2013-01-30 00:22:52 +00:00
Jordan Lee
1d3bf93618
synchronize the Qt and GTK+ client's statusbars, including the new freespace indicator. Make the up/down speed ordering consistent between statusbar and torrent list.
2013-01-27 23:05:47 +00:00
Jordan Lee
6002ffdc37
(gtk) #5235 'Plural wrong in torrent-cell-renderer' -- fix with patch by RamsesDeNorre
2013-01-21 00:15:21 +00:00
Jordan Lee
aea6d7cd6f
(trunk, libT) #5168 'make libtransmission's public funcs nonblocking when possible' -- remove tr_torrentRef() and tr_torrentUnref() as discussed in https://trac.transmissionbt.com/ticket/5168#comment:8
2012-12-14 20:04:37 +00:00
Jordan Lee
079c78981c
(trunk) #5168 'make libtransmission's public funcs nonblocking when possible' -- first attempt.
2012-12-12 20:22:57 +00:00
Jordan Lee
3d38723ad9
Follow more common whitespace style conventions in the C code (libtransmission, daemon, utils, cli, gtk).
2012-12-05 17:29:46 +00:00
Jordan Lee
7219f26dae
(trunk, T) #5072 "In the torrent list, show how many web seeds we're downloading from" -- made the Qt, GTK+, and web client text consistent
2012-10-07 17:51:56 +00:00
Jordan Lee
3946dd2452
minor plural fix for cell renderer downloading metadata, patch by ajf88
2012-09-20 03:39:00 +00:00
Jordan Lee
cdd71c6427
(trunk gtk) #4970 remove deprecated GTK+ API calls, raise GTK+ dependency to 3.2
2012-07-14 19:26:55 +00:00
Jordan Lee
84afa05662
(trunk) Roll back the right-to-left progressbar behavior added in #4281 -- it confused too many people.
2011-09-01 22:49:35 +00:00
Jordan Lee
7ab14ad4b1
(trunk gtk) in torrent-cell-renderer and tr-core, use the _parent_class field generated by G_DEFINE_TYPE.
2011-08-09 06:31:33 +00:00
Jordan Lee
6290169099
(trunk gtk) use G_DEFINE_TYPE when implementing the tr-core and torent-cell-renderer classes
2011-08-09 05:47:24 +00:00
Jordan Lee
7554955eb8
queuing: fix false "Error" message reported by rb07
2011-08-08 16:38:22 +00:00
Jordan Lee
0e48418f26
(trunk gtk) since we're bumping glib's requirement to 2.26 (27 Sept 2010), it's a good time to bump the gtk+ requirement to 2.22 (32 Sept 2010).
2011-08-07 18:41:13 +00:00
Jordan Lee
270126820a
(trunk gtk) bump the glib2 requirement from 2.8 to 2.26 s.t. transmission-gtk can use glib's GDBus module and drop the glib-dbus library dependency
2011-08-07 16:42:38 +00:00
Jordan Lee
307754e807
#671 "torrent queuing" -- modify the queue implementation s.t. every torrent has a queuePosition, even if it's not currently in the queue.
2011-08-02 03:59:54 +00:00
Jordan Lee
2e9d419bd4
#671 "torrent queuing" -- add a tr_stat.isStalled flag.
2011-08-01 23:27:11 +00:00
Jordan Lee
61174b007e
(trunk) #671 "torrent queuing" -- Preliminary implementation. Covers libtransmission; GTK+ and Qt clients, and rudimentary web client support.
2011-08-01 22:24:24 +00:00
Jordan Lee
ee20cc2b24
(trunk gtk) #4320 "Port GTK client to GTK 3." -- transmission-gtk now compiles cleanly & runs on GTK 3.
2011-07-26 01:02:32 +00:00
Jordan Lee
c1d5b4a7e6
(trunk, GTK+/Qt) #4281 "Visualize seed progress like the web client does" -- done, with a modified patch & suggestion from mag
2011-05-28 00:09:15 +00:00
Jordan Lee
45bdc18210
(trunk gtk) use ngettext() instead of gtr_dngettext() to address https://bugs.launchpad.net/ubuntu/+source/transmission/+bug/760761
2011-05-02 17:58:27 +00:00
Jordan Lee
b797f51144
(trunk gtk) more heap pruning: give torrent-cell-renderer an internal GString buffer so that we don't have to create & free so many short-term strings
2011-04-12 10:04:05 +00:00
Jordan Lee
375694eda9
(trunk) copyediting: remove some unneeded #includes, and annotate some needed ones
2011-03-24 21:49:42 +00:00
Jordan Lee
e46d0a72ba
(trunk gtk) gtr_cell_renderer_get_padding() is only used in one place, so make it a private function there instead of leaving it public in util.h
2011-03-24 18:24:21 +00:00
Jordan Lee
c7006ed8b3
(trunk gtk) remove the TrTorrent GObject subclass.
2011-03-03 01:59:25 +00:00
Jordan Lee
72f9ab91fa
(trunk) make tr_torrentName() a public function.
...
This has been a private function in libtransmission for awhile now but it makes more sense as a public function.
2011-02-15 15:18:51 +00:00
Jordan Lee
92def6b960
(trunk gtk) #3887 : "CPU spikes to 100% on scrolling" -- workaround committed.
...
The patch avoids use of GtkCellRendererText's "sensitive" property, and instead renders paused torrents' text using the widget's style's color for insensitive text. This approach honors the theme's "insensitive" color setting and uses it to draw insensitive text with no etching or shadowing.
The better option is still for Murrine to fix its text shadow issue... but until then, here is a workaround.
2011-01-22 13:26:44 +00:00
Jordan Lee
879a2afcbd
Update the copyright year in the source code comments.
...
The Berne Convention says that the copyright year is moot, so instead of adding another year to each file as in previous years, I've removed the year altogether from the source code comments in libtransmission, gtk, qt, utils, daemon, and cli.
Juliusz's copyright notice in tr-dht and Johannes' copyright notice in tr-lpd have been left alone; it didn't seem appropriate to modify them.
2011-01-19 13:48:47 +00:00
Jordan Lee
aea8d8d0b5
(trunk gtk) #3519 "webseeds don't work" -- fix webseed peer counts and download speeds in the GTK+ client's main window
2011-01-06 02:40:10 +00:00
Charles Kerr
992623756c
(trunk gtk) #3847 "GTK+ 3 transition: use accessor functions unstead of direct access" -- use GTK_CELL_RENDERER() macro for casting a TorrentCellRenderer to a GtkCellRenderer. Thanks to ijuxda for the suggestion.
2010-12-27 23:49:45 +00:00
Charles Kerr
e5bb3205a1
(trunk) Join the 21st century and use only 1 space at the end sentences. This commit is nearly as important as the semi-annual ones that remove trailing spaces from the ends of lines of code... :)
2010-12-27 19:18:17 +00:00
Charles Kerr
f5b13c46dc
(trunk gtk) #3847 "GTK+ 3 transition: Use accessor functions instead direct access" -- don't directly access GtkCellRenderer.xpad, GtkCellRenderer.ypad, or GtkWidget.window.
2010-12-24 09:04:52 +00:00