summaryrefslogtreecommitdiff
path: root/src/gtk
AgeCommit message (Collapse)AuthorFilesLines
2009-11-10Add theoretical support for holding weak pointers to stuff that was evicted ↵Daniel Burrows1-3/+95
from the cache. Not tested because calculation of screenshot sizes seems to be screwy.
2009-11-10Use a key extractor for the package name -> screenshot mapping, so we don't ↵Daniel Burrows1-26/+8
have to use the screenshot as its own identity.
2009-11-10Theoretically add screenshot thumbnails into the entity summary pane.Daniel Burrows1-0/+16
2009-11-10Actually add the screenshot to its containing EventBox.Daniel Burrows1-0/+1
Without this, obviously the screenshot wouldn't show up.
2009-11-10Remove an unnecessary call to image.show() in the screenshot code.Daniel Burrows1-1/+0
It only needs to be shown when the screenshot is constructed.
2009-11-09Make images not clickable by default.Daniel Burrows1-1/+2
2009-11-09Overhaul how download failures are handled, for better logging and so the ↵Daniel Burrows2-11/+51
icon hopefully shows up more reliably.
2009-11-09Factor out the code to set up the "missing" icon.Daniel Burrows2-21/+22
2009-11-09Make the screenshot class always have a GdkWindow, and add support for ↵Daniel Burrows3-48/+86
displaying a "missing image" icon when a screenshot can't be downloaded.
2009-11-06The new Glade changed a bunch of lines on its own.Daniel Burrows1-25/+25
2009-11-06Give the screenshot a properly named tag, and insert a thumbnail into the ↵Daniel Burrows3-11/+60
description window that links to the full screenshot.
2009-11-06Don't make screenshots self-show.Daniel Burrows1-1/+0
2009-11-05Add support for an EventBox-based screenshot wrapper that has support for ↵Daniel Burrows2-0/+77
acting as a "link".
2009-11-05Don't create an initial pixbuf loader; wait till we get a partial download.Daniel Burrows1-1/+1
2009-11-05Slightly more idiomatic test for a missing pixbuf loader.Daniel Burrows1-1/+1
2009-11-05More logging of incremental loads.Daniel Burrows1-0/+3
2009-11-05Use an intermediate method to process area updates of screenshots.Daniel Burrows2-1/+12
Mostly useful for logging purposes.
2009-11-05Better logging around incremental loading of screenshots.Daniel Burrows1-0/+4
2009-11-05Fix the order of arguments to lseek64.Daniel Burrows1-1/+1
2009-11-05Log when we decide not to try incremental loading.Daniel Burrows1-0/+7
2009-11-05Fix the signature of screenshot_cache_entry::partial_download so it actually ↵Daniel Burrows1-4/+5
overrides the base class method.
2009-11-05Add more copious logging of download events on screenshots.Daniel Burrows1-0/+10
2009-11-05Use separate logging categories for the screenshot cache and the image widget.Daniel Burrows2-29/+29
2009-11-05Create a screenshot_key object that encapsulates the information needed to ↵Daniel Burrows3-81/+38
identify a particular screenshot.
2009-11-05Actually add entries into the screenshot cache and return previously ↵Daniel Burrows1-7/+28
existing entries when a new one is looked up.
2009-11-05Redesign how the screenshot object handles canceling downloads.Daniel Burrows2-74/+25
Now the client of the object is supposed to manually cancel the download. Although I originally preferred an approach where the widget would detect its own visibility, arguably the user of the object is in a better position to know exactly when to cancel the download.
2009-11-05Log a message when a new image has been loaded for a screenshot.Daniel Burrows1-0/+4
2009-11-05Cleanly handle errors from Gdk::PixbufLoader::close().Daniel Burrows1-3/+43
2009-11-05Don't erase invalid iterators when dropping screenshots from the cache.Daniel Burrows1-1/+1
2009-11-05Add a first cut of a widget to actually display screenshots.Daniel Burrows4-0/+295
The widget was supposed to detect when it was visible or obscured and alter the caching / download status of the screenshot accordingly. I can't figure out how to get it to do that. As a result, the plumbing into the info tab is also a little hokey. Probably the end result here will be that the user of the screenshot image object will be expected to invoke a method when it's not visible any more, since it doesn't seem to be possible for the widget to detect this itself. :-(
2009-11-04Make redirect_from_background derive from sigc::trackable, so it actually ↵Daniel Burrows1-1/+1
fulfils its intended purpose. The whole point here was to exploit sigc::trackable's magic ability to disconnect slots when it's destroyed. This worrks better if you use a sigc::trackable.
2009-11-04Don't start the download in the constructor of screenshot cache entries, so ↵Daniel Burrows1-0/+12
that we can get a shared pointer to the entry (which isn't possible until after the constructor runs).
2009-11-04Make sure to always close() the PixbufLoader when we're done with it; GTK+ ↵Daniel Burrows1-0/+15
doesn't like it when we destroy an unclosed loader.
2009-11-04Add definitions of some missing members of screenshot_cache.Daniel Burrows1-0/+3
2009-11-04Move ~cached_screenshot() into the .cc file, since it can't be inlined anyway.Daniel Burrows2-3/+5
2009-11-04Implement gui::get_screenshot().Daniel Burrows1-0/+6
2009-11-04Initial implementation of code to download screenshots from the GUI.Daniel Burrows3-0/+755
This handles a lot of niceties, at least theoretically (still untested): incremental loading, merging requests for the same screenshot (so only one pixbuf is allocated), and caching loaded screenshots.
2009-11-03Rename resolver_trampoline to post_thunk and move it to the main GUI header.Daniel Burrows5-18/+15
This is preparation for a future where it will be used more generally than just in the resolver.
2009-10-27Don't try to compute a new solution every time the resolver state changes in ↵Daniel Burrows1-2/+1
the upgrade fixing resolver tab. Instead, we just ensure that the first solution is generated. The main symptom of this bug was that if you ran out of solutions, then loosened a constraint so that new solutions were available, a new solution would be produced immediately.
2009-10-27When manipulating resolver entries in the GUI, copy the choices that we're ↵Daniel Burrows2-35/+46
working on before acting on any of them. This fixes crashes caused by the fact that acting on a choice could cause the tree store to be torn down and rebuilt. When we were operating on iterators of the store, this meant that the next item we operated on would access freed memory and crash.
2009-10-26Clean up a minor potential deadlock if the execution of a thunk posted to ↵Daniel Burrows1-5/+45
the main thread generated a bunch of new posted thunks. The write buffer for the glib dispatcher could have become full; now we make sure to never post to it more than once.
2009-10-26Get rid of get_solution_background_blocking.Daniel Burrows2-15/+12
Now that the resolver continuations run in the foreground thread, this was causing irreconcilable deadlocks (since the foreground thread would be waiting for someone to post the return result, which could only happen when the foreground thread finished running the continuation and polled for new posted thunks).
2009-10-26Fix a typo in a text string.Daniel Burrows1-1/+1
2009-10-26Fix up more places where the wrong version was being displayed.Daniel Burrows1-14/+12
2009-10-24Also make checking for cached changelogs based on the job queue object.Daniel Burrows1-183/+73
2009-10-24Use the new job queue class to parse package changelogs.Daniel Burrows1-173/+61
2009-10-11Don't crash if we try to stop the background changelog parse threads and ↵Daniel Burrows1-2/+4
they aren't running.
2009-10-11Make the second tab in the upgrade view display a summary of the selected ↵Daniel Burrows1-17/+7
package (like the one shown in the package search tab) rather than the full changelog of that package.
2009-10-11Suspend the background changelog threads while the cache is closed.Daniel Burrows1-16/+122
Fixes crashes that happened if you closed the program (or, probably, installed software) while downloading changelogs.
2009-10-11Run resolver continuations in the foreground thread via a trampoline callback.Daniel Burrows3-18/+50
This eliminates a whole class of bugs caused by calling into resolver routines from the background thread. The specific one I ran into here was that the resolver thread is shut down by join()ing it while its global lock is held, and it's hard to avoid that -- but most resolver routines want to take the global lock, so calling them from the background thread risks a deadlock. There is a loophole here: you can safely use the resolver manager in the background thread if you know that no-one else is accessing it. The command line frontend uses this to simplify its code.