Show
Ignore:
Timestamp:
05/06/08 04:50:29 (7 months ago)
Author:
flynd
Message:

Moved eventSent signal from mainwin to licqgui.

Location:
trunk/qt4-gui/src/userevents
Files:
4 modified

Legend:

Unmodified
Added
Removed
  • trunk/qt4-gui/src/userevents/usersendcommon.cpp

    r6182 r6185  
    404404    gUserManager.DropUser(u); 
    405405 
    406     connect(gMainWindow, SIGNAL(signal_sentevent(ICQEvent*)), 
    407         myHistoryView, SLOT(addMsg(ICQEvent*))); 
     406    connect(LicqGui::instance(), SIGNAL(eventSent(const ICQEvent*)), 
     407        myHistoryView, SLOT(addMsg(const ICQEvent*))); 
    408408    //myViewSplitter->setResizeMode(myHistoryView, QSplitter::FollowSizeHint); 
    409409  } 
     
    12001200    if (sendDone(e)) 
    12011201    { 
    1202       emit gMainWindow->signal_sentevent(e); 
     1202      emit eventSent(e); 
    12031203      if (Config::Chat::instance()->msgChatView() && myHistoryView != NULL) 
    12041204      { 
  • trunk/qt4-gui/src/userevents/usersendcommon.h

    r6108 r6185  
    6161  void updateUser(CICQSignal* sig); 
    6262  void msgTypeChanged(UserSendCommon* from, UserSendCommon* to); 
     63 
     64  /** 
     65   * Since daemon doesn't notify us when an event is sent we'll have to handle 
     66   * it ourselfs. This signal is sent to notify other windows about the event 
     67   * that was sent. 
     68   * 
     69   * @param event Event object that was sent 
     70   */ 
     71  void eventSent(const ICQEvent* event); 
    6372 
    6473public slots: 
  • trunk/qt4-gui/src/userevents/userviewevent.cpp

    r6166 r6185  
    2323#include "config.h" 
    2424 
     25#include <QAction> 
    2526#include <QApplication> 
    2627#include <QCheckBox> 
     
    4849#include "core/gui-defines.h" 
    4950#include "core/licqgui.h" 
    50 #include "core/mainwin.h" 
    5151#include "core/messagebox.h" 
    5252#include "core/signalmanager.h" 
     
    9090  connect(myMessageList, SIGNAL(currentItemChanged(QTreeWidgetItem*, QTreeWidgetItem*)), 
    9191      SLOT(printMessage(QTreeWidgetItem*))); 
    92   connect(gMainWindow, SIGNAL(signal_sentevent(ICQEvent*)), 
    93       SLOT(sentEvent(ICQEvent*))); 
     92  connect(LicqGui::instance(), SIGNAL(eventSent(const ICQEvent*)), 
     93      SLOT(sentEvent(const ICQEvent*))); 
    9494 
    9595  myActionsBox = new QGroupBox(); 
     
    779779} 
    780780 
    781 void UserViewEvent::sentEvent(ICQEvent* e) 
     781void UserViewEvent::sentEvent(const ICQEvent* e) 
    782782{ 
    783783  if (e->PPID() != myPpid || strcmp(myUsers.front().c_str(), e->Id()) != 0) 
     
    785785 
    786786  if (!Config::Chat::instance()->msgChatView()) 
    787     new MessageListItem(e->GrabUserEvent(), myCodec, myMessageList); 
     787    new MessageListItem(e->UserEvent(), myCodec, myMessageList); 
    788788} 
    789789 
  • trunk/qt4-gui/src/userevents/userviewevent.h

    r6166 r6185  
    8282  void msgTypeChanged(UserSendCommon* from, UserSendCommon* to); 
    8383  void printMessage(QTreeWidgetItem* item); 
    84   void sentEvent(ICQEvent* e); 
     84  void sentEvent(const ICQEvent* e); 
    8585  void setEncoding(); 
    8686};