Changeset c3a47c9
- Timestamp:
- Jan 30, 2010, 9:26:54 PM (15 years ago)
- Branches:
- master, release-1.10, release-1.6, release-1.7, release-1.8, release-1.9
- Children:
- 9a023d0
- Parents:
- fde6d80
- git-author:
- Anders Kaseorg <andersk@mit.edu> (01/25/10 21:56:47)
- git-committer:
- Anders Kaseorg <andersk@mit.edu> (01/30/10 21:26:54)
- Files:
-
- 3 edited
Legend:
- Unmodified
- Added
- Removed
-
filter.c
r3cc4bfc rc3a47c9 24 24 f->fgcolor=OWL_COLOR_DEFAULT; 25 25 f->bgcolor=OWL_COLOR_DEFAULT; 26 f->cachedmsgid=-1;27 26 28 27 /* first take arguments that have to come first */ … … 189 188 } 190 189 191 void owl_filter_set_cachedmsgid(owl_filter *f, int cachedmsgid)192 {193 f->cachedmsgid=cachedmsgid;194 }195 196 int owl_filter_get_cachedmsgid(const owl_filter *f)197 {198 return(f->cachedmsgid);199 }200 201 190 /* return 1 if the message matches the given filter, otherwise 202 191 * return 0. -
owl.h
ra999d9e rc3a47c9 426 426 int fgcolor; 427 427 int bgcolor; 428 int cachedmsgid; /* cached msgid: should move into view eventually */429 428 } owl_filter; 430 429 … … 434 433 owl_messagelist ml; 435 434 const owl_style *style; 435 int cachedmsgid; 436 436 } owl_view; 437 437 -
view.c
r9e5c9f3 rc3a47c9 126 126 int cachedid; 127 127 128 cachedid =owl_filter_get_cachedmsgid(v->filter);128 cachedid = v->cachedmsgid; 129 129 if (cachedid<0) return(0); 130 130 return (owl_view_get_nearest_to_msgid(v, cachedid)); 131 131 } 132 132 133 /* saves the current message position in the filter so it can134 * be restored later if we switch back to this filter. */135 133 void owl_view_save_curmsgid(owl_view *v, int curid) 136 134 { 137 owl_filter_set_cachedmsgid(v->filter, curid);135 v->cachedmsgid = curid; 138 136 } 139 137
Note: See TracChangeset
for help on using the changeset viewer.