Mike Gelfand
d3b8982195
Uppercase the literal suffixes
...
* MISRA C++:2008, 2-13-4 - Literal suffixes shall be upper case
* MISRA C:2012, 7.3 - The lowercase character "l" shall not be used in a
literal suffix
* CERT DCL16-C. - Use "L," not "l," to indicate a long value
* CERT, DCL50-J. - Use visually distinct identifiers
2019-03-17 07:07:48 +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
8f3cb1c68d
Wrap sizeof arguments in braces
2017-05-20 19:29:23 +03:00
Mike Gelfand
1e3d20422a
Reduce for loop variables scope
2017-05-14 01:38:31 +03:00
Mike Gelfand
14370e5353
Fix a number of other style inconsistencies met along the way (part 2)
2017-05-01 18:47:49 +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
ecd1eb7914
Update file icon when its name changes in details dialog (GTK+ client)
...
Additionally, make main window redraw the torrent so that new name and icon
are visible right away.
2017-02-21 23:21:25 +03:00
Mike Gelfand
2248d3670f
Get rid of $Id$ SVN keywords in source files
2016-09-02 23:10:15 +03:00
Mike Gelfand
c955c04d8f
Explicitly compare result of str(n)cmp/memcmp to signify that it's not boolean
2016-03-13 22:11:01 +00: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
4c8bda8805
function pointer type correctness. mikedld
2013-09-08 17:08:18 +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
7cbb20279b
use consistent code indentation/whitespace in open dialog, file list, and set location dialog
2013-07-20 16:19:15 +00:00
Jordan Lee
d1571bda02
(gtk) use replace strcmp() with g_strcmp0() everywhere
2013-02-14 15:17:42 +00:00
Jordan Lee
90b95697e0
(gtk) #5284 'file tree should show the wanted size of the subtree, not the entire size': done.
2013-02-09 19:28:38 +00:00
Jordan Lee
03ac81e7c7
(trunk) #1220 'change top folder names' -- add file-renaming to the GTK+ GUI
2013-01-19 08:44:23 +00:00
Jordan Lee
2a52ebab20
(gtk) copyediting: use G_SOURCE_REMOVE and G_SOURCE_CONTINUE where appropriate
2013-01-04 16:36:52 +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
4c8c5f578d
(trunk gtk) #4764 "filenames should have a tooltip" -- fixed with patch from gulyan
2012-03-04 13:12:42 +00:00
Jordan Lee
6d1869c33b
remove the gtr_timeout_add_seconds() portability wrapper around gdk_threads_add_timeout_seconds(); it's unnecessary now that the minimum gtk version's been bumped.
2011-08-08 17:06:46 +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
1d7a4eb528
(trunk gtk) more heap pruning: minor GtkTreeModel changes
...
Use gtk_tree_model_iter_nth_child() instead of gtk_tree_model_get_iter_first() to avoid an unnecessary gtk_tree_path object being created and destroyed. This is a very minor change and I'm not sure how useful it really is, but it doesn't hurt.
2011-04-13 22:00:55 +00:00
Jordan Lee
c16406bf7c
(trunk gtk) remove "dead nested assignment" wart detected by clang static analyzer
2011-03-31 04:58:38 +00:00
Jordan Lee
eb06d81fb9
(trunk) fix a handful of small memory leaks that valgrind found.
2011-03-25 17:42:47 +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
018585d3b0
(trunk gtk) fix condition that could crash in some cases when right-clicking in the file list menu.
2011-03-13 16:45:32 +00:00
Jordan Lee
c7006ed8b3
(trunk gtk) remove the TrTorrent GObject subclass.
2011-03-03 01:59:25 +00:00
Jordan Lee
dede299e04
(trunk gtk) #3866 "popup menu for file list manipulation" -- remove unused code in file-list.c
...
This code can be pulled back out of svn and readded if it's needed in the future.
2011-02-15 15:21:22 +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
24b9dc7dc2
(trunk gtk) #3866 "Popup menu for file list manipulation" -- removing from the 2.20 milestone
...
Looking over the 2.20 tickets, this one keeps sticking out. A popup menu may be useful if the "delete files" ticket is accepted in 2.30, but for this release (2.20) it doesn't really add anything new. One lesson from the 2.1x cycle was that features are a harder to remove than to add. So I'm going to hold off on adding this feature until it has a clear raison d'être.
2011-02-06 18:50:35 +00:00
Jordan Lee
705b27d128
(trunk gtk) #3876 "Give filesize its own column in the Files tree" -- fix minor memory leak introduced by r11642
...
r11642 allocated a pango font description with pango_font_description_copy() but never freed it.
2011-02-01 17:42:50 +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
721cd1c3c3
(trunk gtk) #3876 "Give filesize its own column in the Files tree" -- added.
2011-01-06 17:21:55 +00:00
Jordan Lee
c48528faf1
(trunk gtk) #3866 "Popup menu for file list manipulation" -- patch by ijuxda + random bugs by me
2011-01-05 07:08:34 +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
057487d18e
(trunk gtk) more gtr_ naming cleanup
2010-12-22 06:25:30 +00:00
Charles Kerr
5eafe91824
(trunk gtk) general cleanup to make function's naming scheme and API more consistent. This is only a fraction of what the GTK+ client's codebase needs, unfortunately.
2010-12-21 19:20:58 +00:00
Charles Kerr
27a1b2dc33
(trunk) one of the periodic, banal "remove-trailing-spaces from lines of source code" cleanup commits
2010-12-12 16:43:19 +00:00
Charles Kerr
e537bdcd4f
(trunk gtk) #3529 "slow priority-sorting in file list" -- fixed
2010-09-17 13:23:20 +00:00
Charles Kerr
6b66524607
(trunk gtk) #3395 "open files by double-clicking on them in the file list" -- added.
2010-07-11 17:56:58 +00:00
Charles Kerr
bb8cef3f14
(trunk gtk) minor code cleanup to the file list
2010-05-12 01:34:08 +00:00
Charles Kerr
33e116f971
(trunk gtk) #2894 "tr_torrentGetFileDL() and tr_torrentGetFilePriority() should go away" -- finished removing them from the GTK+ client
2010-02-11 14:55:00 +00:00
Charles Kerr
c51611f202
(trunk gtk) make the GTK+ client's file list a little faster
2010-02-11 14:45:03 +00:00
Charles Kerr
28726d031d
(trunk gtk) make it easier to change the periodic refresh intervals at the code level
2010-02-01 04:54:10 +00:00