#include <nsIURI.h> // required before nsILink.h
#include <nsILink.h>
#include <nsIPrefBranch.h>
+#if MOZ_VERSION_MAJOR > 1 || (MOZ_VERSION_MAJOR == 1 && MOZ_VERSION_MINOR >= 8)
+# include <nsPresContext.h>
+#else
+# include <nsIPresContext.h>
+ typedef nsIPresContext nsPresContext; // ugh
+#endif
#include <nsIPrefService.h>
-#include <nsIPresContext.h>
#include <nsIPresShell.h>
-#include <nsIServiceManagerUtils.h>
+#if MOZ_VERSION_MAJOR > 1 || (MOZ_VERSION_MAJOR == 1 && MOZ_VERSION_MINOR >= 8)
+# include <nsServiceManagerUtils.h>
+#else
+# include <nsIServiceManagerUtils.h>
+#endif
#include <nsIWebBrowser.h>
#include <nsString.h>
bool process_page();
void save_screenshot();
void process_links(nsIPresShell * pres_shell,
- nsIPresContext * pres_context,
+ nsPresContext * pres_context,
nsIDOMWindow * dom_window);
video::frame_params frame_params_;
: frame_params_(frame_params),
output_dir_(output_dir),
encoder_(encoder),
- stylesheet_(load_css("file://" VIDEOLINK_LIB_DIR "/videolink.css")),
+ stylesheet_(load_css("file://" VIDEOLINK_SHARE_DIR "/videolink.css")),
pending_window_update_(false),
pending_req_count_(0),
have_tweaked_page_(false),
assert(doc_shell);
nsCOMPtr<nsIPresShell> pres_shell;
check(doc_shell->GetPresShell(getter_AddRefs(pres_shell)));
- nsCOMPtr<nsIPresContext> pres_context;
+ nsCOMPtr<nsPresContext> pres_context;
check(doc_shell->GetPresContext(getter_AddRefs(pres_context)));
nsCOMPtr<nsIDOMWindow> dom_window;
check(browser->GetContentDOMWindow(getter_AddRefs(dom_window)));
};
void videolink_window::process_links(nsIPresShell * pres_shell,
- nsIPresContext * pres_context,
+ nsPresContext * pres_context,
nsIDOMWindow * dom_window)
{
Glib::RefPtr<Gdk::Window> window(get_window());
check(event_state_man->SetContentState(content,
NS_EVENT_STATE_HOVER));
- pres_shell->FlushPendingNotifications(true);
+# if MOZ_VERSION_MAJOR > 1 \
+ || (MOZ_VERSION_MAJOR == 1 && MOZ_VERSION_MINOR >= 8)
+ pres_shell->FlushPendingNotifications(Flush_Display);
+# else
+ pres_shell->FlushPendingNotifications(true);
+# endif
// We may have to exit and wait for image loading
// to complete, at which point we will be called