# HG changeset patch # User Santeri Piippo # Date 1375318213 -10800 # Node ID 0f40c56fde23515e4c3d30a290223597332b9719 # Parent a52c30a4c04109874479dd8c99ebf37618307776 some further little optimization diff -r a52c30a4c041 -r 0f40c56fde23 src/gui_actions.cpp --- a/src/gui_actions.cpp Thu Aug 01 03:44:38 2013 +0300 +++ b/src/gui_actions.cpp Thu Aug 01 03:50:13 2013 +0300 @@ -331,11 +331,12 @@ for (LDObject* obj : objs) { LDFile::current()->insertObj (idx, obj); g_win->sel() << obj; + g_win->R()->compileObject( obj ); idx++; } - g_win->fullRefresh(); + g_win->refresh(); g_win->scrollToSelection(); } @@ -392,10 +393,11 @@ LDFile::current()->insertObj (idx, obj); g_win->sel() << obj; + g_win->R()->compileObject( obj ); idx++; } - g_win->fullRefresh(); + g_win->refresh(); g_win->scrollToSelection(); } @@ -433,7 +435,7 @@ for (LDObject* obj : g_win->sel()) obj->setHidden (!obj->hidden()); - g_win->fullRefresh(); + g_win->refresh(); } DEFINE_ACTION (Wireframe, 0) { diff -r a52c30a4c041 -r 0f40c56fde23 src/gui_editactions.cpp --- a/src/gui_editactions.cpp Thu Aug 01 03:44:38 2013 +0300 +++ b/src/gui_editactions.cpp Thu Aug 01 03:50:13 2013 +0300 @@ -137,6 +137,7 @@ LDObject* newobj = parseLine (line); LDFile::current()->insertObj (idx++, newobj); g_win->sel() << newobj; + g_win->R()->compileObject( inlineobj ); } // Delete the subfile now as it's been inlined. @@ -144,7 +145,7 @@ delete obj; } - g_win->fullRefresh(); + g_win->refresh(); } DEFINE_ACTION (Inline, CTRL (I)) { @@ -179,6 +180,9 @@ LDFile::current()->setObject (index, triangles[0]); LDFile::current()->insertObj (index + 1, triangles[1]); + for( LDTriangleObject* t : triangles ) + g_win->R()->compileObject( t ); + // Delete this quad now, it has been split. delete obj; @@ -186,7 +190,7 @@ } log ("%1 quadrilaterals split", num); - g_win->fullRefresh(); + g_win->refresh(); } // ============================================================================= @@ -496,11 +500,12 @@ } obj->setVertex (i, v); + g_win->R()->compileObject( obj ); num += 3; } log (ForgeWindow::tr ("Rounded %1 coordinates"), num); - g_win->fullRefresh(); + g_win->refresh(); } // ============================================================================= @@ -519,11 +524,12 @@ col = edgecolor; obj->setColor (col); + g_win->R()->compileObject( obj ); num++; } log (ForgeWindow::tr ("%1 objects uncolored"), num); - g_win->fullRefresh(); + g_win->refresh(); } // ============================================================================= @@ -564,10 +570,11 @@ } obj->setVertex (i, v); + g_win->R()->compileObject( obj ); } log (ForgeWindow::tr ("Altered %1 values"), num); - g_win->fullRefresh(); + g_win->refresh(); } // ================================================================================================