Project

General

Profile

0001-pass-unknown-commands-to-the-server.patch

admin, 09/16/2008 12:56 PM

View differences:

src/common/message.h
45 45
    Kill   = 0x0200,
46 46
    Server = 0x0400,
47 47
    Info   = 0x0800,
48
    Error  = 0x1000
48
    Error  = 0x1000,
49
    Raw    = 0x2000
49 50
  };
50 51

  
51 52
  // DO NOT CHANGE without knowing what you do, some of these flags are stored in the database
src/core/userinputhandler.cpp
364 364
      return;
365 365
    }
366 366
  }
367
  emit displayMsg(Message::Error, BufferInfo::StatusBuffer, "", QString("Error: %1 %2").arg(cmd).arg(msg));
367
  emit displayMsg(Message::Raw, BufferInfo::StatusBuffer, "", QString("%1 %2").arg(cmd.toUpper()).arg(msg));
368
  emit putCmd(serverEncode(cmd), serverEncode(msg));
368 369
}
369 370

  
370 371
void UserInputHandler::expand(const QString &alias, const BufferInfo &bufferInfo, const QString &msg) {
src/uisupport/uistyle.cpp
87 87
  _formatCodes["%Dr"] = RenameMsg;
88 88
  _formatCodes["%Dm"] = ModeMsg;
89 89
  _formatCodes["%Da"] = ActionMsg;
90
  _formatCodes["%Dz"] = RawMsg;
90 91

  
91 92
  _formatCodes["%DT"] = Timestamp;
92 93
  _formatCodes["%DS"] = Sender;
......
366 367
      s = tr("%Da-*-");
367 368
      t = tr("%Da%DN%1%DN %2").arg(nick).arg(txt);
368 369
      break;
370
    case Message::Raw:
371
      s = tr("%Dz>");
372
      t = tr("%Dz%1").arg(txt);
373
      break;
369 374
    default:
370 375
      s = tr("%De%1").arg(msg.sender());
371 376
      t = tr("%De[%1]").arg(txt);
src/uisupport/uistyle.h
61 61
      RenameMsg       = 0x00000009,
62 62
      ModeMsg         = 0x0000000a,
63 63
      ActionMsg       = 0x0000000b,
64
      RawMsg          = 0x0000000c,
64 65
      // Standard Formats
65 66
      Bold            = 0x00000010,
66 67
      Italic          = 0x00000020,
67
-