comparison app/src/main/java/org/tn5250j/framework/tn5250/Rect.java @ 438:d29cce60f393

migrate from Eclipse to Android Studio
author Carl Byington <carl@five-ten-sg.com>
date Thu, 03 Dec 2015 11:23:55 -0800
parents src/org/tn5250j/framework/tn5250/Rect.java@77ac18bc1b2f
children
comparison
equal deleted inserted replaced
437:208b31032318 438:d29cce60f393
1 /**
2 * $Id: Rect.java 1092 2011-01-16 20:27:56Z master_jaf $
3 *
4 * Title: tn5250J
5 * Copyright: Copyright (c) 2001,2009
6 * Company:
7 * @author: master_jaf
8 *
9 * Description:
10 *
11 * This program is free software; you can redistribute it and/or modify
12 * it under the terms of the GNU General Public License as published by
13 * the Free Software Foundation; either version 2, or (at your option)
14 * any later version.
15 *
16 * This program is distributed in the hope that it will be useful,
17 * but WITHOUT ANY WARRANTY; without even the implied warranty of
18 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
19 * GNU General Public License for more details.
20 *
21 * You should have received a copy of the GNU General Public License
22 * along with this software; see the file COPYING. If not, write to
23 * the Free Software Foundation, Inc., 59 Temple Place, Suite 330,
24 * Boston, MA 02111-1307 USA
25 *
26 */
27 package org.tn5250j.framework.tn5250;
28
29
30 /**
31 * Simplified rectangle class. Very much similar like java.awt.Rectangle,
32 * but we want to decouple the packages ...
33 */
34 public class Rect {
35
36 /* default */ int x;
37 /* default */ int y;
38 /* default */ int height;
39 /* default */ int width;
40
41 /**
42 * @param rect
43 */
44 public void setBounds(Rect rect) {
45 setBounds(rect.x, rect.y, rect.width, rect.height);
46 }
47
48 /**
49 * @param x the new X coordinate for the upper-left corner of this rectangle
50 * @param y the new Y coordinate for the upper-left corner of this rectangle
51 * @param width the new width for this rectangle
52 * @param height the new height for this rectangle
53 */
54 public void setBounds(int x, int y, int width, int height) {
55 this.x = x;
56 this.y = y;
57 this.width = width;
58 this.height = height;
59 }
60
61 }