Commit Graph

9242 Commits

Author SHA1 Message Date
Matthias Clasen
24df69b283 Add a note about tooltip limitations
Apparently Windows only shows the first 64 characters of tooltips
on statusicons. Bug 594600.
2009-09-11 12:47:32 -04:00
Alexander Larsson
0df4283574 Don't use magic zero height/width argument to gdk_window_clear_area
This is an undocumented feature that we stopped supporting, and
anyway it likely only ever worked on X anyway.
2009-09-11 15:08:14 +02:00
Kristian Rietveld
fef3c88e89 Unbreak GtkComboBox::button-sensitivity
Fixed the button-sensivity patch done to GtkComboBox to account for
changes in appearance (changes to the appears-as-list style property).
Also, in list-mode, the event box that has been created below the cell
view also needs to have its sensitivity updated.
2009-09-09 21:30:13 +02:00
Matthias Clasen
3dd459caea Accept "true" as a true value in printer settings
Some of the settings come directly from cups config files, which
have no case sensitivity requirement, so we should not be more
picky.  Bug 594652.
2009-09-09 11:52:07 -04:00
Matthias Clasen
0ea5787fca Fix a typo 2009-09-09 00:03:15 -04:00
Matthias Clasen
308fade38c Make the custom paper size dialog not block the main dialog
This was causing problems in gedit, which uses window groups.
Bug 593678.
2009-09-09 00:03:14 -04:00
Kristian Rietveld
16c5339ea8 Don't access the parent level, there might not be one
Use the index instead, that can be -1.  A unit test has been added as
well.
2009-09-08 15:52:18 +02:00
Paolo Borelli
4e78b4c7d1 One more unit test 2009-09-07 11:17:49 +02:00
Paolo Borelli
04a58d8757 Simple expander unit test 2009-09-07 09:14:21 +02:00
Kristian Rietveld
f77042aae2 Avoid recursive calls to gtk_tree_view_top_row_to_dy()
Commit 3f306a4042 made it possible for
gtk_tree_view_top_row_to_dy() to be called recursively.  (In a different
way than was already guarded for).  This caused a single test case in
the scrolling test suite to fail.  We now also guard for recursive calls at
the beginning of gtk_tree_view_top_row_to_dy().
2009-09-06 20:26:09 +02:00
Kristian Rietveld
a59c39f370 Bug 346800 - Rework sort/filter models to use indices to parents...
Rework the sort and filter models to store their reference to the parent
element as an array index instead of a pointer to an array element.
These pointers could become invalid with any array modification, whereas
indices do not.
2009-09-06 14:12:46 +02:00
Kristian Rietveld
d0051a46f7 Fix compiler warnings 2009-09-05 17:15:43 +02:00
Kristian Rietveld
855fee8f1f Fix memleak in filter model unit test
(There is one larger memleak left here, but this is a side effect of the
test case for bug 346800).
2009-09-05 17:15:43 +02:00
Kristian Rietveld
c2f6611e4b List work left to do in the filter model unit test 2009-09-05 17:15:43 +02:00
Kristian Rietveld
f483c5b7d6 Emit row-has-child-toggled when a first node becomes visible in a level
If we have a level with zero visible nodes and the first node becomes
visible in that level, then parent has just become a "real" parent node.
In such a case we need to emit row-has-child-toggled.  This only applies
to non-root levels that have a parent.  This problem was also found when
writing the unit test, the respective cases in the unit test have been
corrected.

This fixes bugs:
 Bug 372010 - Filtering not working properly
 Bug 525965 - Filtered and sorted GtkTreeView is missing rows
2009-09-05 17:15:42 +02:00
Kristian Rietveld
0c4f29e857 When the filter removes a node, it needs to remove its children too
In gtk_tree_model_filter_remove_node(), we check if the given elt has
children.  If so, this level will be freed.  This action is recursive.
2009-09-05 17:15:42 +02:00
Kristian Rietveld
bf573a1e1e Have the unit test check if the filter model emits the right signals 2009-09-05 17:15:42 +02:00
Kristian Rietveld
14c8149daf Properly handle cases where an ancestor node is invisible 2009-09-05 17:15:42 +02:00
Kristian Rietveld
bbb5bbb591 Extend filter model unit test with row-has-child-toggled testers 2009-09-05 17:15:42 +02:00
Kristian Rietveld
733e532c59 Correct handling of row-has-child-toggled signal
When a filter function is used that determines the visibility property
of a node using whether or it it has children, the state of this node
very likely changes when the filter model receives a
row-has-child-toggled signal.  Therefore, we need to handle state
changes in the row-has-child-toggled handler.
2009-09-05 17:15:42 +02:00
Kristian Rietveld
6606989019 Remove unused variable 2009-09-05 17:15:42 +02:00
Kristian Rietveld
5b766102fd More virtual root unit tests 2009-09-05 17:15:42 +02:00
Kristian Rietveld
7b1d2de75e Add a rather specially crafted test case 2009-09-05 17:15:42 +02:00
Kristian Rietveld
af73305d37 Marking nodes invisible after pulling in the root level is wrong 2009-09-05 17:15:42 +02:00
Kristian Rietveld
532eccabde Do not emit has-child-toggled when a root level node is removed 2009-09-05 17:15:42 +02:00
Kristian Rietveld
15fdf44501 Correct unfiltered test cases 2009-09-05 17:15:41 +02:00
Kristian Rietveld
18b20416e5 Check for successfull iterator retrieval 2009-09-05 17:15:41 +02:00
Kristian Rietveld
958f772c24 Refilter is required after setting visible column 2009-09-05 17:15:41 +02:00
Kristian Rietveld
2cca680c66 Correct /FilterModel/empty/vroot-show-nodes test case 2009-09-05 17:15:41 +02:00
Kristian Rietveld
d09c2ae965 Only emit row-inserted if all ancestors are visible 2009-09-05 17:15:41 +02:00
Kristian Rietveld
378a6dffce Generalize fixture setup code 2009-09-05 17:15:41 +02:00
Kristian Rietveld
b6559c31a7 Make a start with virtual root unit tests 2009-09-05 17:15:41 +02:00
Kristian Rietveld
93b29a9cff Add test cases for bugs 464173 and 529287 2009-09-05 17:15:41 +02:00
Kristian Rietveld
6f2aff35f7 Add unit test for bug 540201 2009-09-05 17:15:41 +02:00
Kristian Rietveld
81bc45ee69 Add a helper for inserting paths in the test tree store 2009-09-05 17:15:41 +02:00
Kristian Rietveld
923a6a8083 Start a testsuite for GtkTreeModelFilter 2009-09-05 17:15:41 +02:00
Matthias Clasen
d6f3af0777 Make gtk_combo_box_entry_set_text_column more forgiving
The assertions in there were unnecessarily restrictive. This has
been reported in bug 564160.
2009-09-04 22:20:28 -04:00
Matthias Clasen
6b7fef09ca Don't forget to set the client window on the slave 2009-09-04 20:34:09 -04:00
Matthias Clasen
1c0ecc0380 Rework the way IM contexts are set
Add a function to obtain the effective context id, and reset the slave
only when the effective context id is different from the current context
id, when setting a client window and on focus in. This might fix
bug 593868 and bug 567124.
2009-09-04 18:09:44 -04:00
Alexander Larsson
812b3c451d Deprecate GDK_WINDOW_OBJECT and GdkWindowObject 2009-09-04 17:59:18 +02:00
Kristian Rietveld
a47aadb05e Protect gtk_text_view_scroll_mark_onscreen() from using invalid marks
Suggested by Paolo Borelli.
2009-09-04 17:40:12 +02:00
Kristian Rietveld
5ec80eb5ba Recalculate heights when a (new) separator func is set on GtkTreeView 2009-09-04 17:08:29 +02:00
Kristian Rietveld
dcc87f7a67 Move mark check to gtk_text_view_scroll_to_mark()
Also use a different means to check that the given mark is in the text
view's buffer.  This will also play nice with anonymous and NULL marks.
Suggested by Paolo Borelli.
2009-09-04 17:08:29 +02:00
Michael Natterer
6ee228a363 gtk_widget_set_property(): use accessors instead of setting flags
Use the newly added accessors to set the "can-focus", "can-default"
and "receives-default" properties.
2009-09-04 15:18:24 +02:00
Michael Natterer
026bea2293 gtk_widget_set_property(): use gtk_widget_set_visible()
Use the new API instead of show() and hide().
2009-09-04 14:54:13 +02:00
Michael Natterer
b81079d898 Bug 69872 - GTK_WIDGET_SET_FLAGS should be deprecated
Add gtk_widget_set_receives_default() and
gtk_widget_get_receives_default() as accessors for
GTK_RECEIVES_DEFAULT.
2009-09-04 14:50:35 +02:00
Kristian Rietveld
dc3fb714a0 Improve unsetting old buffer in gtk_text_view_set_buffer()
When unsetting the old buffer always set the buffer on the layout to
NULL.  More importantly, clear the pending scroll.  (The scroll is
handled in an idle, when not cleared an idle handler might touch the
layout later on, possibly corrupting the BTree).  Unref the buffer after
removing the selection from the clipboard, not before.  Patch merged
from maemo-gtk.
2009-09-04 14:06:59 +02:00
Kristian Rietveld
7a3d98324d Fail to scroll if the given mark is not in text view's current buffer
In gtk_text_view_queue_scroll() we need to verify if the given mark
exists in the text view's current buffer.  When not done, this can
result in corruption of the BTree data structure.  Patch merged from
maemo-gtk.
2009-09-04 14:06:58 +02:00
Kristian Rietveld
3a917a2a67 Update IM spot location before running _validate_onscreen()
Updating the IM spot location in gtk_text_view_value_changed() might
invalidate the layout, so we need to make sure that we update it before
validating the layout again.  Otherwise, the layout will be invalidated
right after validating it (possibly resulting in a failed
onscreen_validated assertion).  Patch merged from maemo-gtk.
2009-09-04 14:06:58 +02:00
Kristian Rietveld
4f219692ed Make toggle cell renderer follow insensitive state of widget
Likewise to other cell renderers, GtkCellRendererToggle now properly
follows the insensitive state of the widget requesting rendering.  It
does this by checking the state of the widget pointer, not by using
GtkCellRendererFlags (there exists an insensitive flags).  Later on, I
think we should move to using GtkCellRendererFlags and not the state of
the widget requesting rendering.  Patch merged from maemo-gtk.
2009-09-04 14:06:58 +02:00