gitlab-org--gitlab-foss/lib/gitlab/diff/image_point.rb
2018-07-09 21:13:08 +08:00

23 lines
383 B
Ruby

module Gitlab
module Diff
class ImagePoint
attr_reader :width, :height, :x, :y
def initialize(width, height, new_x, new_y)
@width = width
@height = height
@x = new_x
@y = new_y
end
def to_h
{
width: width,
height: height,
x: x,
y: y
}
end
end
end
end