~ubuntu-branches/ubuntu/jaunty/quassel/jaunty

« back to all changes in this revision

Viewing changes to src/common/message.h

  • Committer: Bazaar Package Importer
  • Author(s): Scott Kitterman
  • Date: 2009-01-14 01:28:49 UTC
  • mfrom: (1.1.5 upstream)
  • Revision ID: james.westby@ubuntu.com-20090114012849-38celzez3y3wpai9
Tags: 0.4.0~git090113-0ubuntu1
* New upstream git snapshot
  - Use networks.ini to provide default network/channel
  - Provide presets for common IRC networks
* Add kubuntu_01_default_network_channel.patch to set Freenode, port
  8001, and #kubuntu as defaults
* Add build-dep on quilt

Show diffs side-by-side

added added

removed removed

Lines of Context:
1
1
/***************************************************************************
2
 
 *   Copyright (C) 2005-08 by the Quassel Project                          *
 
2
 *   Copyright (C) 2005-09 by the Quassel Project                          *
3
3
 *   devel@quassel-irc.org                                                 *
4
4
 *                                                                         *
5
5
 *   This program is free software; you can redistribute it and/or modify  *
66
66
          const QString &contents = "", const QString &sender = "", Flags flags = None);
67
67
 
68
68
  inline static Message ChangeOfDay(const QDateTime &day) { return Message(day, BufferInfo(), DayChange, tr("Day changed to %1").arg(day.toString("dddd MMMM d yyyy"))); }
69
 
  inline MsgId msgId() const { return _msgId; }
 
69
  inline const MsgId &msgId() const { return _msgId; }
70
70
  inline void setMsgId(MsgId id) { _msgId = id; }
71
71
 
72
 
  inline BufferInfo bufferInfo() const { return _bufferInfo; }
73
 
  inline QString contents() const { return _contents; }
74
 
  inline QString sender() const { return _sender; }
 
72
  inline const BufferInfo &bufferInfo() const { return _bufferInfo; }
 
73
  inline const BufferId &bufferId() const { return _bufferInfo.bufferId(); }
 
74
  inline void setBufferId(BufferId id) { _bufferInfo.setBufferId(id); }
 
75
  inline const QString &contents() const { return _contents; }
 
76
  inline const QString &sender() const { return _sender; }
75
77
  inline Type type() const { return _type; }
76
78
  inline Flags flags() const { return _flags; }
77
 
  inline QDateTime timestamp() const { return _timestamp; }
 
79
  inline void setFlags(Flags flags) { _flags = flags; }
 
80
  inline const QDateTime &timestamp() const { return _timestamp; }
78
81
 
79
 
  void setFlags(Flags flags);
 
82
  inline bool isValid() const { return _msgId.isValid(); }
80
83
 
81
84
  inline bool operator<(const Message &other) const { return _msgId < other._msgId; }
82
85
 
89
92
  Type _type;
90
93
  Flags _flags;
91
94
 
92
 
  QString _formattedTimestamp, _formattedSender, _formattedText; // cache
93
 
 
94
95
  friend QDataStream &operator>>(QDataStream &in, Message &msg);
95
96
};
96
97