[prev in list] [next in list] [prev in thread] [next in thread]
List: kde-commits
Subject: kdenonbeta/kopete/libkopete/ui
From: Jason Keirstead <jason () keirstead ! org>
Date: 2003-03-15 2:20:38
[Download RAW message or body]
CVS commit by brunes:
Ensure that the contact still exists before showign ther KC popup
M +14 -4 chatview.cpp 1.204
--- kdenonbeta/kopete/libkopete/ui/chatview.cpp #1.203:1.204
@@ -889,4 +889,5 @@ void ChatView::slotRefreshNodes()
void ChatView::slotRightClick( const QString &, const QPoint &point )
{
+ KPopupMenu *chatWindowPopup = new KPopupMenu();
Node n = chatView->nodeUnderMouse();
if( n.nodeType() == Node::TEXT_NODE )
@@ -897,11 +898,20 @@ void ChatView::slotRightClick( const QSt
{
KopeteMessage m = messageFromNode( e );
- if( !m.to().isEmpty() )
+ if( msgManager()->members().contains( m.from() ) )
+ {
((KopeteContact*)m.from())->showContextMenu( point );
+ delete chatWindowPopup;
+ chatWindowPopup = 0L;
}
else
{
- KPopupMenu *chatWindowPopup = new KPopupMenu();
+ chatWindowPopup->insertItem( i18n("User has left"), 1 );
+ chatWindowPopup->setItemEnabled( 1, false );
+ chatWindowPopup->insertSeparator();
+ }
+ }
+ if( chatWindowPopup )
+ {
if( !n.isNull() )
{
[prev in list] [next in list] [prev in thread] [next in thread]
Configure |
About |
News |
Add a list |
Sponsored by KoreLogic