item.ref();
int64 delay = item.get_meta_integer ("delay");
- if (delay == -2 && view.can_reload ()) {
+ if (delay == -2 && view.progress < 1.0) {
this.schedule_reload (browser, view);
}
}
if (this.timeout != 0)
this.tasks.set (browser, new TabShaker (browser));
- if (view.can_reload ())
+ if (view.progress < 1.0)
this.schedule_reload (browser, view);
return false;
_action_set_sensitive (browser, "AddSpeedDial", !midori_view_is_blank (view));
_action_set_sensitive (browser, "BookmarkAdd", !midori_view_is_blank (view));
_action_set_sensitive (browser, "SaveAs", midori_view_can_save (view));
- _action_set_sensitive (browser, "Print", midori_view_can_print (view));
_action_set_sensitive (browser, "ZoomIn", midori_view_can_zoom_in (view));
_action_set_sensitive (browser, "ZoomOut", midori_view_can_zoom_out (view));
_action_set_sensitive (browser, "ZoomNormal",
midori_view_can_view_source (view));
_action_set_sensitive (browser, "SourceView",
midori_view_can_view_source (view));
- _action_set_sensitive (browser, "Find",
- midori_view_can_find (view));
- _action_set_sensitive (browser, "FindNext",
- midori_view_can_find (view));
- _action_set_sensitive (browser, "FindPrevious",
- midori_view_can_find (view));
- midori_findbar_set_can_find (MIDORI_FINDBAR (browser->find),
- midori_view_can_find (view));
action = _action_by_name (browser, "NextForward");
if (midori_view_can_go_forward (view))
return unique_filename;
}
-#define can_do(what) \
-gboolean \
-midori_view_can_##what (MidoriView* view) \
-{ \
- g_return_val_if_fail (MIDORI_IS_VIEW (view), FALSE); \
-\
- return view->web_view != NULL; \
-}
-
-can_do (reload)
-can_do (print)
-can_do (find)
-
/**
* midori_view_reload:
* @view: a #MidoriView
midori_view_set_zoom_level (MidoriView* view,
gfloat zoom_level);
-gboolean
-midori_view_can_reload (MidoriView* view);
-
void
midori_view_reload (MidoriView* view,
gboolean from_cache);
const gchar*
midori_view_get_next_page (MidoriView* view);
-gboolean
-midori_view_can_print (MidoriView* view);
-
void
midori_view_print (MidoriView* view);
const gchar* uri,
const gchar* outfile);
-gboolean
-midori_view_can_find (MidoriView* view);
-
void
midori_view_unmark_text_matches (MidoriView* view);
public Gtk.Label get_proxy_tab_label ();
public Katze.Item get_proxy_item ();
public bool can_view_source ();
- public bool can_find ();
public void search_text (string text, bool case_sensitive, bool forward);
public void mark_text_matches (string text, bool case_sensitive);
public void set_highlight_text_matches (bool highlight);
public Gdk.Pixbuf get_snapshot (int width, int height);
public unowned WebKit.WebView get_web_view ();
public void populate_popup (Gtk.Menu menu, bool manual);
- public bool can_reload ();
public void reload (bool from_cache);
public string uri { get; }