Changeset 1b8c3f8


Ignore:
Timestamp:
Sep 18, 2010, 5:07:40 PM (14 years ago)
Author:
David Benjamin <davidben@mit.edu>
Branches:
master, release-1.10, release-1.7, release-1.8, release-1.9
Children:
4a41f16
Parents:
dcd48ad
git-author:
David Benjamin <davidben@mit.edu> (09/16/10 17:10:21)
git-committer:
David Benjamin <davidben@mit.edu> (09/18/10 17:07:40)
Message:
owl_viewwin doesn't need to keep track of cmdline
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • owl.h

    r9c1e61d4 r1b8c3f8  
    418418  gulong sig_status_redraw_id;
    419419  owl_window *cmdwin;
    420   owl_editwin *cmdline;
    421420} owl_viewwin;
    422421 
  • viewwin.c

    rd2fd2f7 r1b8c3f8  
    242242owl_editwin *owl_viewwin_set_typwin_active(owl_viewwin *v, owl_history *hist) {
    243243  int lines, cols;
    244   if (v->cmdwin || v->cmdline)
     244  owl_editwin *cmdline;
     245  if (v->cmdwin)
    245246    return NULL;
    246247  /* Create the command line. */
     
    248249  owl_viewwin_layout(v);
    249250  owl_window_get_position(v->cmdwin, &lines, &cols, NULL, NULL);
    250   v->cmdline = owl_editwin_new(v->cmdwin, lines, cols, OWL_EDITWIN_STYLE_ONELINE, hist);
     251  cmdline = owl_editwin_new(v->cmdwin, lines, cols, OWL_EDITWIN_STYLE_ONELINE, hist);
    251252  /* Swap out the bottom window. */
    252253  owl_window_hide(v->status);
    253254  owl_window_show(v->cmdwin);
    254   return v->cmdline;
     255  return cmdline;
    255256}
    256257
     
    264265    g_object_unref(v->cmdwin);
    265266    v->cmdwin = NULL;
    266   }
    267   if (v->cmdline) {
    268     owl_editwin_unref(v->cmdline);
    269     v->cmdline = NULL;
    270267  }
    271268}
Note: See TracChangeset for help on using the changeset viewer.