Explorar el Código

removed unused method

Ivan Savenko hace 2 años
padre
commit
ae9f040abf

+ 1 - 1
client/battle/BattleInterfaceClasses.cpp

@@ -738,7 +738,7 @@ boost::optional<uint32_t> StackQueue::getHoveredUnitIdIfAny() const
 {
 	for(const auto & stackBox : stackBoxes)
 	{
-		if(stackBox->hovered || stackBox->mouseState(EIntObjMouseBtnType::RIGHT))
+		if(stackBox->hovered || stackBox->mouseState(MouseButton::RIGHT))
 		{
 			return stackBox->getBoundUnitID();
 		}

+ 0 - 8
client/renderSDL/SDL_Extensions.cpp

@@ -384,14 +384,6 @@ uint32_t CSDL_Ext::colorTouint32_t(const SDL_Color * color)
 	return ret;
 }
 
-void CSDL_Ext::update(SDL_Surface * what)
-{
-	if(!what)
-		return;
-	if(0 !=SDL_UpdateTexture(screenTexture, nullptr, what->pixels, what->pitch))
-		logGlobal->error("%s SDL_UpdateTexture %s", __FUNCTION__, SDL_GetError());
-}
-
 static void drawLineX(SDL_Surface * sur, int x1, int y1, int x2, int y2, const SDL_Color & color1, const SDL_Color & color2)
 {
 	for(int x = x1; x <= x2; x++)

+ 0 - 2
client/renderSDL/SDL_Extensions.h

@@ -111,7 +111,6 @@ typedef void (*TColorPutterAlpha)(uint8_t *&ptr, const uint8_t & R, const uint8_
 	/// returns dimensions of display on which VCMI window is located
 	Rect getDisplayBounds();
 
-	void update(SDL_Surface * what = screen); //updates whole surface (default - main screen)
 	void drawLine(SDL_Surface * sur, int x1, int y1, int x2, int y2, const SDL_Color & color1, const SDL_Color & color2);
 	void drawBorder(SDL_Surface * sur, int x, int y, int w, int h, const SDL_Color &color, int depth = 1);
 	void drawBorder(SDL_Surface * sur, const Rect &r, const SDL_Color &color, int depth = 1);
@@ -138,7 +137,6 @@ typedef void (*TColorPutterAlpha)(uint8_t *&ptr, const uint8_t & R, const uint8_
 
 	///set key-color to 0,255,255
 	void setDefaultColorKey(SDL_Surface * surface);
-
 	///set key-color to 0,255,255 only if it exactly mapped
 	void setDefaultColorKeyPresize(SDL_Surface * surface);