Changeset 673


Ignore:
Timestamp:
May 16, 2011, 2:37:39 AM (9 years ago)
Author:
Sam Hocevar
Message:

imlib: remove the unused redraw event code.

Location:
abuse/trunk
Files:
5 edited

Legend:

Unmodified
Added
Removed
  • abuse/trunk/TODO

    r672 r673  
    7373refactor image::Line to merge loops
    7474
    75 event::redraw::x1,y1...
    7675view::cx1,cx2...
    7776
  • abuse/trunk/src/game.cpp

    r671 r673  
    17841784                                draw();
    17851785                            } break;
    1786                             case EV_REDRAW:
    1787                             {
    1788                                 main_screen->AddDirty(vec2i(ev.redraw.x1, ev.redraw.y1),
    1789                                     vec2i(ev.redraw.x2 + 1, ev.redraw.y2 + 1));
    1790                             } break;
    17911786                            case EV_MESSAGE:
    17921787                            {
  • abuse/trunk/src/imlib/event.cpp

    r669 r673  
    113113}
    114114
    115 //
    116 // add_redraw()
    117 // Add a redraw rectangle.
    118 //
    119 void EventHandler::add_redraw(int X1, int Y1, int X2, int Y2, void *start)
    120 {
    121     Event *ev;
    122     ev = new Event;
    123     ev->type = EV_REDRAW;
    124     ev->redraw.x1 = X1;
    125     ev->redraw.x2 = X2;
    126     ev->redraw.y1 = Y1;
    127     ev->redraw.y2 = Y2;
    128     ev->redraw.start = start;
    129     Push(ev);
    130 }
    131 
  • abuse/trunk/src/imlib/event.h

    r669 r673  
    1515#define EV_KEY            4
    1616#define EV_KEY_SPECIAL    8
    17 #define EV_REDRAW        16
     17/* #define EV_REDRAW        16 UNUSED */
    1818#define EV_SPURIOUS      32
    1919#define EV_RESIZE        64
     
    5252
    5353    struct { char alt, ctrl, shift; } key_special;
    54     struct { int x1, y1, x2, y2; void *start; } redraw;
    5554
    5655    Jwindow *window;      // NULL is root
     
    7473    void SysEvent(Event &ev);
    7574
    76   int IsPending();
    77   void Get(Event &ev);
    78   void add_redraw(int X1, int Y1, int X2, int Y2, void *Start);
     75    int IsPending();
     76    void Get(Event &ev);
    7977  void flush_screen();
    8078
  • abuse/trunk/src/imlib/jwindow.cpp

    r671 r673  
    201201       ev.window_position.y=ev.mouse_move.y+drag_mousey;
    202202    }
    203   }
    204   if (ev.type == EV_REDRAW)
    205   {
    206     for (Jwindow *j = m_first; j; j = j->next)
    207        j->m_surf->AddDirty(vec2i(ev.redraw.x1, ev.redraw.y1) - j->m_pos,
    208                            vec2i(ev.redraw.x2 + 1, ev.redraw.y2 + 1) - j->m_pos.x);
    209     m_surf->AddDirty(vec2i(ev.redraw.x1, ev.redraw.y1),
    210                      vec2i(ev.redraw.x2 + 1, ev.redraw.y2 + 1));
    211     flush_screen();
    212     ev.type=EV_SPURIOUS;   // we took care of this one by ourselves.
    213203  }
    214204}
Note: See TracChangeset for help on using the changeset viewer.