![]() |
![]() |
![]() |
Libfm Reference Manual | ![]() |
---|---|---|---|---|
Top | Description | Object Hierarchy |
#define FM_NAV_HISTORY_TYPE struct FmNavHistory; struct FmNavHistoryClass; struct FmNavHistoryItem; void fm_nav_history_back (FmNavHistory *nh
,int old_scroll_pos
); gboolean fm_nav_history_can_back (FmNavHistory *nh
); gboolean fm_nav_history_can_forward (FmNavHistory *nh
); void fm_nav_history_chdir (FmNavHistory *nh
,FmPath *path
,int old_scroll_pos
); void fm_nav_history_clear (FmNavHistory *nh
); void fm_nav_history_forward (FmNavHistory *nh
,int old_scroll_pos
); const FmNavHistoryItem * fm_nav_history_get_cur (FmNavHistory *nh
); const GList * fm_nav_history_get_cur_link (FmNavHistory *nh
); void fm_nav_history_jump (FmNavHistory *nh
,GList *l
,int old_scroll_pos
); const GList * fm_nav_history_list (FmNavHistory *nh
); FmNavHistory * fm_nav_history_new (void
); void fm_nav_history_set_max (FmNavHistory *nh
,guint num
);
include
: libfm/fm-nav-history.h
The FmNavHistory object implements history for paths that were entered in some input bar and allows to add, remove or move items in it.
struct FmNavHistoryItem { FmPath* path; int scroll_pos; };
FmPath * |
active path to folder |
how much folder was scrolled in view |
void fm_nav_history_back (FmNavHistory *nh
,int old_scroll_pos
);
If there is a next item in the history then sets old_scroll_pos
into
current item data and marks next item current.
|
the history |
|
the scroll position to associate with current item |
Since 0.1.0
gboolean fm_nav_history_can_back (FmNavHistory *nh
);
Checks if current selected item is the first item in the history.
Before 1.0.0 this call had name fm_nav_history_get_can_back.
|
the history |
Returns : |
TRUE if cursor can go backward in history. |
Since 0.1.0
gboolean fm_nav_history_can_forward (FmNavHistory *nh
);
Checks if current selected item is the last item in the history.
Before 1.0.0 this call had name fm_nav_history_get_can_forward.
|
the history |
Returns : |
TRUE if cursor can go forward in history. |
Since 0.1.0
void fm_nav_history_chdir (FmNavHistory *nh
,FmPath *path
,int old_scroll_pos
);
Sets old_scroll_pos
into current item data and then adds new path
to the beginning of the nh
.
|
the history |
|
new path to add |
|
the scroll position to associate with current item |
Since 0.1.0
void fm_nav_history_clear (FmNavHistory *nh
);
Removes all items from the history nh
.
|
the history |
Since 0.1.0
void fm_nav_history_forward (FmNavHistory *nh
,int old_scroll_pos
);
If there is a previous item in the history then sets old_scroll_pos
into current item data and marks previous item current.
|
the history |
|
the scroll position to associate with current item |
Since 0.1.0
const FmNavHistoryItem * fm_nav_history_get_cur (FmNavHistory *nh
);
Retrieves current selected item of the history. The returned item belongs to FmNavHistory and shouldn't be freed by caller.
|
the history |
Returns : |
current item. [transfer none] |
Since 0.1.0
const GList * fm_nav_history_get_cur_link (FmNavHistory *nh
);
Retrieves current selected item as GList element containing FmNavHistoryItem. The returned item belongs to FmNavHistory and shouldn't be freed by caller.
|
the history |
Returns : |
(element-type FmNavHistoryItem): current item. [transfer none] |
Since 0.1.0
void fm_nav_history_jump (FmNavHistory *nh
,GList *l
,int old_scroll_pos
);
Sets old_scroll_pos
into current item data and then
sets current item of nh
to one from l
.
|
the history |
|
new current item. [element-type #FmNavHistoryItem] |
|
the scroll position to associate with current item |
Since 0.1.0
const GList * fm_nav_history_list (FmNavHistory *nh
);
Retrieves full list of the history as GList of FmNavHistoryItem. The returned GList belongs to FmNavHistory and shouldn't be freed.
|
the history |
Returns : |
(element-type FmNavHistoryItem): full history. [transfer none] |
Since 0.1.0
FmNavHistory * fm_nav_history_new (void
);
Creates a new FmNavHistory object with empty history.
Returns : |
a new FmNavHistory object. |
Since 0.1.0
void fm_nav_history_set_max (FmNavHistory *nh
,guint num
);
Sets maximum length of the history nh
to be num
.
|
the history |
|
new size of history |
Since 0.1.0