Integrating github/staging through commit ab87ed9
This commit is contained in:
@@ -257,7 +257,6 @@ bool EDITOR_COMMON_API ShowBatchFileDialog(Serialization::StringList* result, co
|
||||
else
|
||||
{
|
||||
string gameFolder = Path::GetEditingGameDataFolder().c_str();
|
||||
int modIndex = 0;
|
||||
string gamePrefix = GetIEditor()->GetPrimaryCDFolder().toUtf8().data();
|
||||
if (!gamePrefix.empty() && gamePrefix[gamePrefix.size() - 1] != '\\')
|
||||
{
|
||||
@@ -338,8 +337,6 @@ bool EDITOR_COMMON_API ShowBatchFileDialog(Serialization::StringList* result, co
|
||||
max(0, center.y() - dialog.height() / 2));
|
||||
}
|
||||
|
||||
int numFailed = 0;
|
||||
int numSaved = 0;
|
||||
std::vector<string> failedFiles;
|
||||
if (dialog.exec() == QDialog::Accepted)
|
||||
{
|
||||
|
||||
@@ -2134,12 +2134,6 @@ void CCurveEditor::UpdateTangents()
|
||||
key.m_inTangent = Vec2(prevKey.m_time - key.m_time, prevKey.m_value - key.m_value) / 3.0f;
|
||||
key.m_outTangent = -key.m_outTangent;
|
||||
}
|
||||
else
|
||||
{
|
||||
SCurveEditorKey& prevKey = curve.m_keys[keyIx - 1];
|
||||
SCurveEditorKey& nextKey = curve.m_keys[keyIx + 1];
|
||||
|
||||
}
|
||||
key.m_bAdded = false;
|
||||
}
|
||||
if (keyIx > 0)
|
||||
|
||||
@@ -124,8 +124,6 @@ namespace Manip
|
||||
QuatT transform = spaceProvider->ElementToWorldSpace(element);
|
||||
Matrix34 transformM(transform);
|
||||
|
||||
bool isHighlighted = element.id == highlightedItem;
|
||||
|
||||
if (element.shape == SHAPE_BOX)
|
||||
{
|
||||
OBB obb;
|
||||
@@ -217,10 +215,6 @@ namespace Manip
|
||||
|
||||
void CScene::OnViewportRender(const SRenderContext& rc)
|
||||
{
|
||||
IRenderer* renderer = GetIEditor()->GetRenderer();
|
||||
IRenderAuxGeom* aux = renderer->GetIRenderAuxGeom();
|
||||
|
||||
|
||||
SignalRenderElements(m_elements, rc);
|
||||
|
||||
for (int xRayPass = 0; xRayPass < 2; ++xRayPass)
|
||||
|
||||
@@ -227,7 +227,6 @@ PropertyRow* PropertyOArchive::updateRowPrimitive(const char* name, const char*
|
||||
bool PropertyOArchive::operator()(const Serialization::SStruct& ser, const char* name, const char* label)
|
||||
{
|
||||
const char* typeName = ser.type().name();
|
||||
size_t size = ser.size();
|
||||
|
||||
lastNode_ = currentNode_;
|
||||
bool hideChildren = outlineMode_ && currentNode_ && currentNode_->isContainer();
|
||||
@@ -352,8 +351,6 @@ bool PropertyOArchive::operator()(double& value, const char* name, const char* l
|
||||
bool PropertyOArchive::operator()(Serialization::IContainer& ser, const char *name, const char *label)
|
||||
{
|
||||
const char* elementTypeName = ser.elementType().name();
|
||||
bool fixedSizeContainer = ser.isFixedSize();
|
||||
lastNode_ = currentNode_;
|
||||
enterNode(updateRow<PropertyRowContainer>(name, label, ser.containerType().name(), ser));
|
||||
|
||||
if (!model_->defaultTypeRegistered(elementTypeName)) {
|
||||
@@ -442,13 +439,9 @@ bool PropertyOArchive::operator()(Serialization::ICallback& callback, const char
|
||||
|
||||
bool PropertyOArchive::operator()(Serialization::Object& obj, const char *name, const char *label)
|
||||
{
|
||||
const char* typeName = obj.type().name();
|
||||
|
||||
PropertyRowObject* row = 0;
|
||||
if (typeName_.empty())
|
||||
row = updateRow<PropertyRowObject>(name, label, obj.type().name(), obj);
|
||||
else
|
||||
row = updateRow<PropertyRowObject>(name, label, obj.type().name(), obj);
|
||||
row = updateRow<PropertyRowObject>(name, label, obj.type().name(), obj);
|
||||
|
||||
lastNode_ = row;
|
||||
return true;
|
||||
}
|
||||
|
||||
@@ -1512,7 +1512,6 @@ void PropertyRow::dropInto(PropertyRow* parentRow, PropertyRow* cursorRow, QProp
|
||||
if(parentRow->isContainer()){
|
||||
tree->model()->rowAboutToBeChanged(tree->model()->root()); // FIXME: select optimal row
|
||||
setSelected(false);
|
||||
PropertyRowContainer* container = static_cast<PropertyRowContainer*>(parentRow);
|
||||
PropertyRow* oldParent = parent();
|
||||
TreePath oldParentPath = tree->model()->pathFromRow(oldParent);
|
||||
oldParent->erase(this);
|
||||
|
||||
@@ -65,7 +65,7 @@ bool PropertyRowLocalFrameBase::onContextMenu(QMenu& menu, QPropertyTree* tree)
|
||||
|
||||
LocalFrameMenuHandler* handler = new LocalFrameMenuHandler(tree, this);
|
||||
|
||||
QAction* action = menu.addAction("Reset", handler, SLOT(onMenuReset()));
|
||||
menu.addAction("Reset", handler, SLOT(onMenuReset()));
|
||||
|
||||
tree->addMenuHandler(handler);
|
||||
return true;
|
||||
|
||||
@@ -31,7 +31,6 @@ void ClassMenuItemAdder::generateMenu(QMenu& createItem, const StringList& combo
|
||||
{
|
||||
StringList path;
|
||||
splitStringList(&path, it->c_str(), '\\');
|
||||
int level = 0;
|
||||
QMenu* item = &createItem;
|
||||
//createItem.addMenu(
|
||||
for (int level2 = 0; level2 < int(path.size()); ++level2)
|
||||
|
||||
@@ -60,7 +60,9 @@ void PropertyTreeModel::selectRow(PropertyRow* row, bool select, bool exclusive)
|
||||
setFocusedRow(row);
|
||||
}
|
||||
else if(it != selection_.end()){
|
||||
#if !defined(NDEBUG)
|
||||
PropertyRow* it_row = rowFromPath(*it);
|
||||
#endif
|
||||
YASLI_ASSERT(it_row->refCount() > 0 && it_row->refCount() < 0xFFFF);
|
||||
selection_.erase(it);
|
||||
}
|
||||
|
||||
@@ -512,7 +512,6 @@ public:
|
||||
bool drop([[maybe_unused]] QPoint screenPoint)
|
||||
{
|
||||
bool rowLayoutChanged = false;
|
||||
PropertyTreeModel* model = tree_->model();
|
||||
if (row_ && hoveredRow_){
|
||||
YASLI_ASSERT(destinationRow_);
|
||||
clickedRow_->setSelected(false);
|
||||
@@ -1187,15 +1186,13 @@ void QPropertyTree::updateHeights(bool recalculateTextSize)
|
||||
|
||||
updateValidatorIcons();
|
||||
|
||||
int padding = 4;
|
||||
|
||||
int totalHeight = 0;
|
||||
model()->root()->adjustVerticalPosition(this, totalHeight);
|
||||
totalHeight += 4;
|
||||
QPoint oldSize = size_;
|
||||
size_.setY(totalHeight);
|
||||
|
||||
bool hasScrollBar = updateScrollBar();
|
||||
updateScrollBar();
|
||||
|
||||
area_.setLeft(widgetRect.left() + 2);
|
||||
area_.setRight(widgetRect.right() - 2 - scrollBarW);
|
||||
@@ -2493,7 +2490,6 @@ void QPropertyTree::paintEvent([[maybe_unused]] QPaintEvent* ev)
|
||||
QPainter painter(this);
|
||||
QRect clientRect = this->rect();
|
||||
|
||||
int clientWidth = clientRect.width();
|
||||
int clientHeight = clientRect.height();
|
||||
backgroundColor_ = palette().color(QPalette::Window);
|
||||
painter.fillRect(clientRect, QBrush(backgroundColor_));
|
||||
@@ -2624,9 +2620,6 @@ void QPropertyTree::mousePressEvent(QMouseEvent* ev)
|
||||
|
||||
if (ev->button() == Qt::LeftButton)
|
||||
{
|
||||
int x = ev->x();
|
||||
int y = ev->y();
|
||||
|
||||
PropertyRow* row = rowByPoint(ev->pos());
|
||||
if (row && !row->isSelectable())
|
||||
row = row->parent();
|
||||
@@ -2698,7 +2691,6 @@ void QPropertyTree::mouseReleaseEvent(QMouseEvent* ev)
|
||||
}
|
||||
else {
|
||||
QPoint point = ev->pos();
|
||||
PropertyRow* row = rowByPoint(point);
|
||||
if (capturedRow_){
|
||||
QRect rowRect = capturedRow_->rect();
|
||||
onRowLMBUp(capturedRow_, rowRect, pointToRootSpace(ev->pos()));
|
||||
|
||||
@@ -102,7 +102,6 @@ static void DrawGridLines(IRenderAuxGeom& aux, const uint count, const uint inte
|
||||
const float alphaMulMain = (float)gridSettings.mainColor.a;
|
||||
const float alphaMulInter = (float)gridSettings.middleColor.a;
|
||||
const float alphaFalloff = 1.0f - (gridSettings.alphaFalloff / 100.0f);
|
||||
float orthoWeight = 1.0f;
|
||||
|
||||
for (int i = 0; i < count + 2; i++)
|
||||
{
|
||||
@@ -303,7 +302,6 @@ bool QViewport::CreateRenderContext()
|
||||
|
||||
HWND windowHandle = reinterpret_cast<HWND>(QWidget::winId());
|
||||
|
||||
ERenderType renderType = GetIEditor()->GetEnv()->pRenderer->GetRenderType();
|
||||
if( AZ::Interface<AzFramework::AtomActiveInterface>::Get() && m_renderContextCreated && windowHandle == m_lastHwnd)
|
||||
{
|
||||
// the hwnd has not changed, no need to destroy and recreate context (and swap chain etc)
|
||||
@@ -577,8 +575,6 @@ void QViewport::ProcessMouse()
|
||||
{
|
||||
if (!(m_settings->camera.transformRestraint & eCameraTransformRestraint_Rotation))
|
||||
{
|
||||
float speedScale = CalculateMoveSpeed(m_fastMode, m_slowMode);
|
||||
|
||||
Ang3 angles(aznumeric_cast<float>(-point.y() + m_mousePressPos.y()), 0, aznumeric_cast<float>(-point.x() + m_mousePressPos.x()));
|
||||
angles = angles * 0.001f * m_settings->camera.rotationSpeed;
|
||||
|
||||
@@ -626,8 +622,6 @@ void QViewport::ProcessMouse()
|
||||
}
|
||||
else if (m_cameraControlMode == CameraControlMode::ORBIT)
|
||||
{
|
||||
float speedScale = CalculateMoveSpeed(m_fastMode, m_slowMode);
|
||||
|
||||
// Rotate around orbit target.
|
||||
QuatT cameraTarget = m_state->cameraTarget;
|
||||
Vec3 at = cameraTarget.t - m_state->orbitTarget;
|
||||
@@ -979,7 +973,6 @@ void QViewport::RenderInternal()
|
||||
SetCurrentContext();
|
||||
GetIEditor()->GetEnv()->pSystem->RenderBegin();
|
||||
|
||||
IRenderAuxGeom* pAuxGeom = GetIEditor()->GetEnv()->pRenderer->GetIRenderAuxGeom();
|
||||
ColorF viewportBackgroundColor(m_settings->background.topColor.r / 255.0f, m_settings->background.topColor.g / 255.0f, m_settings->background.topColor.b / 255.0f);
|
||||
GetIEditor()->GetEnv()->pRenderer->ClearTargetsImmediately(FRT_CLEAR, viewportBackgroundColor);
|
||||
GetIEditor()->GetEnv()->pRenderer->ResetToDefault();
|
||||
|
||||
@@ -477,7 +477,6 @@ namespace Serialization {
|
||||
{
|
||||
while (isComment(*cur.end))
|
||||
{
|
||||
const char* commentStart = ptr;
|
||||
while (*cur.end && *cur.end != '\n')
|
||||
{
|
||||
++cur.end;
|
||||
@@ -969,7 +968,10 @@ namespace Serialization {
|
||||
ser(*this);
|
||||
CRY_ASSERT(!stack_.empty());
|
||||
stack_.pop_back();
|
||||
bool closed = closeBracket();
|
||||
#if !defined(NDEBUG)
|
||||
bool closed =
|
||||
#endif
|
||||
closeBracket();
|
||||
CRY_ASSERT(closed);
|
||||
return true;
|
||||
}
|
||||
|
||||
@@ -984,7 +984,7 @@ namespace
|
||||
float rx = radius * 200.0f / ratio;
|
||||
float ry = radius * 200.0f;
|
||||
|
||||
if (pass == PASS_SHADOW)
|
||||
if (pass == PASS_SELECTION)
|
||||
{
|
||||
if (bSelected)
|
||||
{
|
||||
@@ -1250,7 +1250,7 @@ struct CTimeline::SMoveHandler
|
||||
|
||||
SAnimTime minDeltaTime = SAnimTime::Min();
|
||||
SAnimTime maxDeltaTime = SAnimTime::Max();
|
||||
SAnimTime minKeyTime = SAnimTime::Max();
|
||||
SAnimTime minKeyTime = SAnimTime::Min();
|
||||
|
||||
for (size_t i = 0; i < selectedElements.size(); ++i)
|
||||
{
|
||||
@@ -1301,7 +1301,7 @@ struct CTimeline::SMoveHandler
|
||||
const QPoint currentPos(ev->pos().x(), ev->pos().y() + scroll);
|
||||
|
||||
QPoint posInLayoutSpace = m_timeline->m_viewState.LocalToLayout(currentPos);
|
||||
bool bHit = HitTestElements(m_timeline->m_layout->tracks, QRect(posInLayoutSpace - QPoint(2, 2), posInLayoutSpace + QPoint(2, 2)), hitElements);
|
||||
HitTestElements(m_timeline->m_layout->tracks, QRect(posInLayoutSpace - QPoint(2, 2), posInLayoutSpace + QPoint(2, 2)), hitElements);
|
||||
|
||||
if (!hitElements.empty())
|
||||
{
|
||||
@@ -1375,8 +1375,6 @@ struct CTimeline::SScrubHandler
|
||||
|
||||
void SetThumbPositionX(int positionX)
|
||||
{
|
||||
int nThumbEndPadding = (THUMB_WIDTH / 2) + 2;
|
||||
float fVisualRange = float(m_timeline->m_viewState.widthPixels - nThumbEndPadding * 2);
|
||||
SAnimTime time = SAnimTime(m_timeline->m_viewState.LayoutToTime(positionX));
|
||||
|
||||
m_timeline->ClampAndSetTime(time, false);
|
||||
@@ -2466,11 +2464,6 @@ void CTimeline::OnMenuPlay()
|
||||
typedef std::vector<std::pair<SAnimTime, STimelineContentElementRef> > TimeToId;
|
||||
static void GetAllTimes(TimeToId* times, const STimelineTrack& track)
|
||||
{
|
||||
for (size_t i = 0; i < track.elements.size(); ++i)
|
||||
{
|
||||
const STimelineElement& element = track.elements[i];
|
||||
}
|
||||
|
||||
for (size_t i = 0; i < track.tracks.size(); ++i)
|
||||
{
|
||||
GetAllTimes(times, *track.tracks[i]);
|
||||
|
||||
@@ -50,7 +50,6 @@ CUnsavedChangedDialog::CUnsavedChangedDialog(QWidget* parent)
|
||||
if (parent)
|
||||
{
|
||||
QPoint center = parent->mapToGlobal(parent->geometry().center());
|
||||
QDesktopWidget* desktop = QApplication::desktop();
|
||||
const QRect screenDimensions = QApplication::screenAt(center)->geometry();
|
||||
if (screenDimensions.contains(center))
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user