diff --git a/Import/GacUI.Windows.cpp b/Import/GacUI.Windows.cpp index 80e9008c..69cbb591 100644 --- a/Import/GacUI.Windows.cpp +++ b/Import/GacUI.Windows.cpp @@ -1347,14 +1347,12 @@ IMPLEMENT_BRUSH_ELEMENT_RENDERER {\ oldColor=Pair(element->GetColor1(), element->GetColor2());\ brush=_renderTarget->CreateDirect2DLinearBrush(oldColor.key, oldColor.value);\ - brush->AddRef();\ }\ }\ void TRENDERER::DestroyBrush(IWindowsDirect2DRenderTarget* _renderTarget)\ {\ if(_renderTarget && brush)\ {\ - brush->Release();\ _renderTarget->DestroyDirect2DLinearBrush(oldColor.key, oldColor.value);\ brush=0;\ }\ diff --git a/Import/GacUI.Windows.h b/Import/GacUI.Windows.h index 3edab95d..894e0d78 100644 --- a/Import/GacUI.Windows.h +++ b/Import/GacUI.Windows.h @@ -1449,9 +1449,9 @@ UniscribeColor UniscribeColor(){} UniscribeColor(Color _fontColor, Color _backgroundColor):fontColor(_fontColor),backgroundColor(_backgroundColor){} - inline vint Compare(const UniscribeColor& value)const + inline vint64_t Compare(const UniscribeColor& value)const { - vint result; + vint64_t result; if ((result = fontColor.Compare(value.fontColor)) != 0) return result; if ((result = backgroundColor.Compare(value.backgroundColor)) != 0) return result; return 0; diff --git a/Import/GacUI.h b/Import/GacUI.h index 7e8a8245..e6d980b4 100644 --- a/Import/GacUI.h +++ b/Import/GacUI.h @@ -536,9 +536,9 @@ Color { } - vint Compare(Color color)const + vint64_t Compare(Color color)const { - return value - color.value; + return (vint64_t)value - (vint64_t)color.value; } GUI_DEFINE_COMPARE_OPERATORS(Color) @@ -9205,9 +9205,9 @@ Colorized Plain Text (model) /// Color background; - inline vint Compare(const ColorItem& value)const + inline vint64_t Compare(const ColorItem& value)const { - vint result; + vint64_t result; if ((result = text.Compare(value.text)) != 0) return result; if ((result = background.Compare(value.background)) != 0) return result; return 0; @@ -9233,9 +9233,9 @@ Colorized Plain Text (model) /// ColorItem selectedUnfocused; - inline vint Compare(const ColorEntry& value)const + inline vint64_t Compare(const ColorEntry& value)const { - vint result; + vint64_t result; if ((result = normal.Compare(value.normal)) != 0) return result; if ((result = selectedFocused.Compare(value.selectedFocused)) != 0) return result; if ((result = selectedUnfocused.Compare(value.selectedUnfocused)) != 0) return result;