Submitted by: eseidel
Reviewed by: darin
* kwq/KWQSize.h:
* kwq/KWQSize.mm:
(QSize::operator CGSize): adding CGSize conversion support
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@9555
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
+2005-07-01 Eric Seidel <eseidel@apple.com>
+
+ Reviewed by darin.
+
+ * kwq/KWQSize.h:
+ * kwq/KWQSize.mm:
+ (QSize::operator CGSize): adding CGSize conversion support
+
2005-06-30 Bruce DiBello <bdibello@apple.com>
Reviewed by Geoff Garen.
#endif
typedef struct _NSSize NSSize;
+typedef struct CGSize CGSize;
class QSize {
public:
QSize expandedTo(const QSize &) const;
operator NSSize() const;
+ operator CGSize() const;
friend QSize operator+(const QSize &, const QSize &);
friend bool operator==(const QSize &, const QSize &);
return NSMakeSize(w, h);
}
+QSize::operator CGSize() const
+{
+ return CGSizeMake(w, h);
+}
+
QSize operator+(const QSize &a, const QSize &b)
{
return QSize(a.w + b.w, a.h + b.h);