本文整理汇总了C#中platform.include.Point2I._vectorFrom方法的典型用法代码示例。如果您正苦于以下问题:C# Point2I._vectorFrom方法的具体用法?C# Point2I._vectorFrom怎么用?C# Point2I._vectorFrom使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类platform.include.Point2I
的用法示例。
在下文中一共展示了Point2I._vectorFrom方法的1个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C#代码示例。
示例1: _moveInfo
__tuple<Point2I, Size2I> _moveInfo(Point2I nPoint)
{
Point2I vector_ = nPoint._vectorFrom(mMouseDown);
__tuple<Point2I, Point2I> tuple_ = this._moveMinMax();
Point2I min_ = tuple_._get_0();
Point2I max_ = tuple_._get_1();
Size2I size_ = new Size2I();
int width_ = max_._getX() - min_._getX();
int height_ = max_._getY() - min_._getY();
size_._setWidth(width_);
size_._setHeight(height_);
Point2I begin_ = new Point2I();
if (vector_._getX() > 0)
{
begin_._setX(max_._getX());
}
else
{
begin_._setX(min_._getX());
}
if (vector_._getY() > 0)
{
begin_._setY(max_._getY());
}
else
{
begin_._setY(min_._getY());
}
Point2I end_ = begin_ + vector_;
ScreenSingleton screenSingleton_ = __singleton<ScreenSingleton>._instance();
end_ = screenSingleton_._normalPoint(end_);
vector_ = end_ - begin_;
return new __tuple<Point2I, Size2I>(vector_, size_);
}