]> git.xonotic.org Git - xonotic/netradiant.git/blobdiff - radiant/brush.h
Merge commit '00a7e0326354f7837338661c2307412f5beba9fb' into master-merge
[xonotic/netradiant.git] / radiant / brush.h
index f258d84afb6694632d0ad1a0ab1081b596c5810e..3249cda0f2d994c4ff0f8aa3eaef260e5238db97 100644 (file)
@@ -599,14 +599,6 @@ void fit( const Vector3& normal, const Winding& winding, float s_repeat, float t
        Texdef_FitTexture( m_projection, m_shader.width(), m_shader.height(), normal, winding, s_repeat, t_repeat );
 }
 
-void fitW( const Vector3& normal, const Winding& winding, float s_repeat, float t_repeat ){
-       Texdef_FitTextureW( m_projection, m_shader.width(), m_shader.height(), normal, winding, s_repeat, t_repeat );
-}
-
-void fitH( const Vector3& normal, const Winding& winding, float s_repeat, float t_repeat ){
-       Texdef_FitTextureH( m_projection, m_shader.width(), m_shader.height(), normal, winding, s_repeat, t_repeat );
-}
-
 void emitTextureCoordinates( Winding& winding, const Vector3& normal, const Matrix4& localToWorld ){
        Texdef_EmitTextureCoordinates( m_projection, m_shader.width(), m_shader.height(), winding, normal, localToWorld );
 }
@@ -1235,18 +1227,6 @@ void FitTexture( float s_repeat, float t_repeat ){
        texdefChanged();
 }
 
-void FitTextureW( float s_repeat, float t_repeat ){
-       undoSave();
-       m_texdef.fitW( m_plane.plane3().normal(), m_winding, s_repeat, t_repeat );
-       texdefChanged();
-}
-
-void FitTextureH( float s_repeat, float t_repeat ){
-       undoSave();
-       m_texdef.fitH( m_plane.plane3().normal(), m_winding, s_repeat, t_repeat );
-       texdefChanged();
-}
-
 void EmitTextureCoordinates(){
        Texdef_EmitTextureCoordinates( m_texdefTransformed, m_shader.width(), m_shader.height(), m_winding, plane3().normal(), g_matrix4_identity );
 }
@@ -3325,6 +3305,11 @@ bool isSelected() const {
 
 void setSelected( bool select ){
        m_selectable.setSelected( select );
+       if ( !select && parent() ){
+               Selectable* sel_parent = Instance_getSelectable( *parent() );
+               if ( sel_parent && sel_parent->isSelected() )
+                       sel_parent->setSelected( false );
+       }
 }
 
 void update_selected() const {