textfield fix
This commit is contained in:
@@ -1,5 +1,6 @@
|
||||
package haxework.gui;
|
||||
|
||||
import flash.geom.Point;
|
||||
import flash.text.TextFieldAutoSize;
|
||||
import haxework.gui.core.HAlign;
|
||||
import haxework.gui.core.VAlign;
|
||||
@@ -151,6 +152,13 @@ class TextView extends SpriteView implements ITextView<Sprite, TextField> {
|
||||
} else {
|
||||
placeTextField(textField);
|
||||
}
|
||||
//ToDo:
|
||||
var t:Point = content.localToGlobal(new Point(textField.x, textField.y));
|
||||
t.x = Math.round(t.x);
|
||||
t.y = Math.round(t.y);
|
||||
t = content.globalToLocal(t);
|
||||
textField.x = t.x;
|
||||
textField.y = t.y;
|
||||
super.update();
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user