aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorfluxgen <fluxgen>2003-08-24 15:39:52 (GMT)
committerfluxgen <fluxgen>2003-08-24 15:39:52 (GMT)
commit6610e1c2101e42f351cf592987bc892a0c72c896 (patch)
tree33a15e5a6682502f9f4ee47bb5bdfa87623fa096
parent710ef5d3c94e82e0ec99ff95a8c09d7308f81a6e (diff)
downloadfluxbox-6610e1c2101e42f351cf592987bc892a0c72c896.zip
fluxbox-6610e1c2101e42f351cf592987bc892a0c72c896.tar.bz2
remove round corners for already shaped windows, i.e xmms
-rw-r--r--src/FbWinFrame.cc17
1 files changed, 15 insertions, 2 deletions
diff --git a/src/FbWinFrame.cc b/src/FbWinFrame.cc
index 9c8989f..ac1db09 100644
--- a/src/FbWinFrame.cc
+++ b/src/FbWinFrame.cc
@@ -19,7 +19,7 @@
19// FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER 19// FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
20// DEALINGS IN THE SOFTWARE. 20// DEALINGS IN THE SOFTWARE.
21 21
22// $Id: FbWinFrame.cc,v 1.40 2003/08/24 11:11:07 fluxgen Exp $ 22// $Id: FbWinFrame.cc,v 1.41 2003/08/24 15:39:52 fluxgen Exp $
23 23
24#include "FbWinFrame.hh" 24#include "FbWinFrame.hh"
25 25
@@ -644,7 +644,7 @@ void FbWinFrame::reconfigure() {
644 if (!m_shaded) 644 if (!m_shaded)
645 renderHandles(); 645 renderHandles();
646 646
647 if (m_shape.get() && theme().shapePlace() == Shape::NONE) 647 if (m_shape.get() && theme().shapePlace() == Shape::NONE || m_disable_shape)
648 m_shape.reset(0); 648 m_shape.reset(0);
649 else if (m_shape.get() == 0 && theme().shapePlace() != Shape::NONE) 649 else if (m_shape.get() == 0 && theme().shapePlace() != Shape::NONE)
650 m_shape.reset(new Shape(window(), theme().shapePlace())); 650 m_shape.reset(new Shape(window(), theme().shapePlace()));
@@ -657,6 +657,15 @@ void FbWinFrame::reconfigure() {
657 // titlebar stuff rendered already by reconftitlebar 657 // titlebar stuff rendered already by reconftitlebar
658} 658}
659 659
660void FbWinFrame::setUseShape(bool value) {
661 m_disable_shape = !value;
662
663 if (m_shape.get() && m_disable_shape)
664 m_shape.reset(0);
665 else if (m_shape.get() == 0 && !m_disable_shape)
666 m_shape.reset(new Shape(window(), theme().shapePlace()));
667}
668
660unsigned int FbWinFrame::buttonHeight() const { 669unsigned int FbWinFrame::buttonHeight() const {
661 return m_titlebar.height() - m_bevel*2; 670 return m_titlebar.height() - m_bevel*2;
662} 671}
@@ -886,6 +895,8 @@ void FbWinFrame::renderButtons() {
886 895
887void FbWinFrame::init() { 896void FbWinFrame::init() {
888 897
898 m_disable_shape = false;
899
889 m_current_label = 0; // no focused button at first 900 m_current_label = 0; // no focused button at first
890 901
891 // clear pixmaps 902 // clear pixmaps
@@ -1065,3 +1076,5 @@ void FbWinFrame::renderButtonUnfocus(FbTk::TextButton &button) {
1065 1076
1066 button.clear(); 1077 button.clear();
1067} 1078}
1079
1080