~ubuntu-branches/ubuntu/oneiric/nux/oneiric

« back to all changes in this revision

Viewing changes to NuxCore/Size.cpp

  • Committer: Bazaar Package Importer
  • Author(s): Sebastien Bacher
  • Date: 2010-12-17 13:59:57 UTC
  • mto: This revision was merged to the branch mainline in revision 8.
  • Revision ID: james.westby@ubuntu.com-20101217135957-5gvg6fkjxaa252i0
Tags: upstream-0.9.12
ImportĀ upstreamĀ versionĀ 0.9.12

Show diffs side-by-side

added added

removed removed

Lines of Context:
32
32
    height_ = h;
33
33
  }
34
34
 
35
 
//----------------------------------------------------------------------------
36
35
  Size::~Size()
37
36
  {
38
37
 
39
38
  }
40
39
 
41
 
//----------------------------------------------------------------------------
42
40
  Size::Size (const Size &s)
43
41
  {
44
42
    width_ = s.width_;
45
43
    height_ = s.height_;
46
44
  }
47
45
 
48
 
//----------------------------------------------------------------------------
49
46
  Size &Size::operator = (const Size &s)
50
47
  {
51
48
    width_ = s.width_;
63
60
    return false;
64
61
  }
65
62
 
66
 
//----------------------------------------------------------------------------
67
63
  t_bool Size::operator!= (const Size &s) const
68
64
  {
69
65
    if ( (width_ == s.width_) && (height_ == s.height_) )
74
70
    return true;
75
71
  }
76
72
 
77
 
//----------------------------------------------------------------------------
78
73
  Size Size::operator+ (const Size &s) const
79
74
  {
80
75
    Size size;
83
78
    return size;
84
79
  }
85
80
 
86
 
//----------------------------------------------------------------------------
87
81
  Size Size::operator- (const Size &s) const
88
82
  {
89
83
    Size size;
92
86
    return size;
93
87
  }
94
88
 
95
 
//----------------------------------------------------------------------------
96
89
  t_int32 Size::GetWidth() const
97
90
  {
98
91
    return width_;
99
92
  }
100
93
 
101
 
//----------------------------------------------------------------------------
102
94
  t_int32 Size::GetHeight() const
103
95
  {
104
96
    return height_;
105
97
  }
106
98
 
107
 
//----------------------------------------------------------------------------
108
99
  void Size::SetWidth (t_int32 w)
109
100
  {
110
101
    width_ = w;
111
102
  }
112
103
 
113
 
//----------------------------------------------------------------------------
114
104
  void Size::SetHeight (t_int32 h)
115
105
  {
116
106
    height_ = h;
117
107
  }
118
 
 
119
 
//----------------------------------------------------------------------------
120
 
 
121
108
}