Add patches to implement proper iconify/resize behaviour.
Patches by xOr, as posted to the blackbox mailinglist (blackbox at trolltech dot com). Bump PKGREVISION.
This commit is contained in:
parent
3fefb9145b
commit
9464330a91
8 changed files with 211 additions and 2 deletions
|
@ -1,8 +1,9 @@
|
|||
# $NetBSD: Makefile,v 1.1.1.1 2002/08/04 16:24:21 jschauma Exp $
|
||||
# $NetBSD: Makefile,v 1.2 2002/08/05 21:42:33 jschauma Exp $
|
||||
#
|
||||
|
||||
DISTNAME= bbappconf-0.0.1-peak3
|
||||
PKGNAME= bbappconf-0.0.1.0.3
|
||||
PKGREVISION= 1
|
||||
CATEGORIES= misc x11 wm
|
||||
MASTER_SITES= http://bbtools.windsofstorm.net/sources/devel/
|
||||
|
||||
|
|
|
@ -1,7 +1,13 @@
|
|||
$NetBSD: distinfo,v 1.1.1.1 2002/08/04 16:24:21 jschauma Exp $
|
||||
$NetBSD: distinfo,v 1.2 2002/08/05 21:42:33 jschauma Exp $
|
||||
|
||||
SHA1 (bbappconf-0.0.1-peak3.tar.gz) = 03698e9ec97872aa36df86c2ecd97922ef22907c
|
||||
Size (bbappconf-0.0.1-peak3.tar.gz) = 80193 bytes
|
||||
SHA1 (patch-aa) = f730864931ec633ffa54e51a42b2d6dfbb127929
|
||||
SHA1 (patch-ab) = 2d45a53624945456a4ca3289ed241b21aee356c4
|
||||
SHA1 (patch-ac) = efdb5217518e3814910a85ecf37c66b45bda46d8
|
||||
SHA1 (patch-ba) = b4e1b15b170ea4ba3e787313cc9dbc68456fb1aa
|
||||
SHA1 (patch-bb) = fd20465664ae43a30487b547b0688e3253fb5f04
|
||||
SHA1 (patch-bc) = d47fb2abd28c7a5c0aa516e70da3c4f87554f592
|
||||
SHA1 (patch-bd) = adc0e81679f6e7fbe830b80e0efe3470c572c4bc
|
||||
SHA1 (patch-be) = 732f449cf865e2e9e1a97a098ccdbb2e6c3538e1
|
||||
SHA1 (patch-bf) = a47c1f6b242fecd06ee6102f4b0a7acf07ae252e
|
||||
|
|
37
misc/bbappconf/patches/patch-ba
Normal file
37
misc/bbappconf/patches/patch-ba
Normal file
|
@ -0,0 +1,37 @@
|
|||
$NetBSD: patch-ba,v 1.1 2002/08/05 21:42:34 jschauma Exp $
|
||||
|
||||
--- appconf.hh.orig Mon Aug 5 17:28:52 2002
|
||||
+++ appconf.hh Mon Aug 5 17:30:01 2002
|
||||
@@ -38,6 +38,11 @@
|
||||
bool getMaxHoriz(void) { return max_horiz;}
|
||||
bool getMaxVert(void) {return max_vert;}
|
||||
|
||||
+ int getPositionX(void) {return position_x;}
|
||||
+ int getPositionY(void) {return position_y;}
|
||||
+ int getWidth(void) {return width;}
|
||||
+ int getHeight(void) {return height;}
|
||||
+
|
||||
char *getName(void) { return appname;}
|
||||
char *getClass(void) { return appclass;}
|
||||
|
||||
@@ -47,6 +52,11 @@
|
||||
void setMaxHoriz(bool _max_horiz) {max_horiz=_max_horiz;}
|
||||
void setStartOnDesktop(unsigned int _start_on_desktop)
|
||||
{start_on_desktop=_start_on_desktop;}
|
||||
+ void setPositionX(int _position_x) {position_x=_position_x;}
|
||||
+ void setPositionY(int _position_y) {position_y=_position_y;}
|
||||
+ void setWidth(int _width) {width=_width;}
|
||||
+ void setHeight(int _height) {height=_height;}
|
||||
+
|
||||
private:
|
||||
|
||||
bool sticky;
|
||||
@@ -54,6 +64,8 @@
|
||||
bool max_horiz;
|
||||
bool max_vert;
|
||||
unsigned int start_on_desktop;
|
||||
+ int position_x, position_y;
|
||||
+ int width, height;
|
||||
char *appname;
|
||||
char *appclass;
|
||||
};
|
45
misc/bbappconf/patches/patch-bb
Normal file
45
misc/bbappconf/patches/patch-bb
Normal file
|
@ -0,0 +1,45 @@
|
|||
$NetBSD: patch-bb,v 1.1 2002/08/05 21:42:34 jschauma Exp $
|
||||
|
||||
--- bbappconf.cc.orig Mon Aug 5 16:52:13 2002
|
||||
+++ bbappconf.cc Mon Aug 5 16:56:41 2002
|
||||
@@ -35,6 +35,8 @@
|
||||
|
||||
config_db = XrmGetFileDatabase("config.bb");
|
||||
|
||||
+ iconic = options->iconic;
|
||||
+
|
||||
desktop_nr=0;
|
||||
current_desktop_nr=-1;
|
||||
wm_init=False;
|
||||
@@ -245,6 +247,18 @@
|
||||
getWMInterface()->sendWindowToDesktop(*win,
|
||||
resource->getAppConf(i)->getStartOnDesktop()-1);
|
||||
}
|
||||
+
|
||||
+ /* set window size */
|
||||
+ if (resource->getAppConf(i)->getWidth()>=0 &&
|
||||
+ resource->getAppConf(i)->getHeight()>=0) {
|
||||
+ getWMInterface()->resizeWindow(*win,resource->getAppConf(i)->getWidth(),resource->getAppConf(i)->getHeight());
|
||||
+ }
|
||||
+ /* set window position */
|
||||
+ if (resource->getAppConf(i)->getPositionX()!=-1111 &&
|
||||
+ resource->getAppConf(i)->getPositionY()!=-1111) {
|
||||
+ getWMInterface()->moveWindow(*win,resource->getAppConf(i)->getPositionX(),resource->getAppConf(i)->getPositionY());
|
||||
+ }
|
||||
+
|
||||
if (resource->getAppConf(i)->getMaxHoriz() ||
|
||||
resource->getAppConf(i)->getMaxVert()) {
|
||||
if (XGetWindowProperty(getXDisplay(), *win,
|
||||
@@ -413,12 +427,6 @@
|
||||
XSetWindowBackgroundPixmap(getXDisplay(), framewin, pixmap.frame);
|
||||
}
|
||||
|
||||
- if (!withdrawn && resource->report.auto_raise) {
|
||||
- XRaiseWindow(getXDisplay(),framewin);
|
||||
- lower=False;
|
||||
- }
|
||||
- else lower=True;
|
||||
-
|
||||
if (!reconfigure) {
|
||||
|
||||
// gcv.font = resource->menu.font->fid;
|
17
misc/bbappconf/patches/patch-bc
Normal file
17
misc/bbappconf/patches/patch-bc
Normal file
|
@ -0,0 +1,17 @@
|
|||
$NetBSD: patch-bc,v 1.1 2002/08/05 21:42:34 jschauma Exp $
|
||||
|
||||
--- bbappconf.hh.orig Mon Aug 5 16:57:10 2002
|
||||
+++ bbappconf.hh Mon Aug 5 17:01:50 2002
|
||||
@@ -97,10 +97,11 @@
|
||||
|
||||
private:
|
||||
|
||||
- bool lower;
|
||||
bool wm_init;
|
||||
int day,month,year;
|
||||
int number_of_icons;
|
||||
+
|
||||
+ bool iconic;
|
||||
|
||||
int current_desktop_nr;
|
||||
PIXMAP pixmap;
|
61
misc/bbappconf/patches/patch-bd
Normal file
61
misc/bbappconf/patches/patch-bd
Normal file
|
@ -0,0 +1,61 @@
|
|||
$NetBSD: patch-bd,v 1.1 2002/08/05 21:42:34 jschauma Exp $
|
||||
|
||||
--- resource.cc.orig Mon Aug 5 17:02:17 2002
|
||||
+++ resource.cc Mon Aug 5 17:04:39 2002
|
||||
@@ -61,6 +61,8 @@
|
||||
int i;
|
||||
char rclass[40];
|
||||
char rname[40];
|
||||
+ int position_x, position_y;
|
||||
+ int width, height;
|
||||
|
||||
if ((XrmGetResource(resource_db, "bbappconf.numberOf.configs",
|
||||
"Bbappconf.NumberOf.Configs",
|
||||
@@ -164,6 +166,47 @@
|
||||
app_conf[i].setMaxHoriz(false);
|
||||
}
|
||||
|
||||
+ sprintf(rclass, "Bbappconf.%d.Width",i+1);
|
||||
+ sprintf(rname, "bbappconf.%d.width",i+1);
|
||||
+ if ((XrmGetResource(resource_db, rname,rclass,&value_type, &value))) {
|
||||
+ if (sscanf(value.addr, "%u", &width) != 1) {
|
||||
+ width = -1;
|
||||
+ }
|
||||
+ } else
|
||||
+ width=-1;
|
||||
+ app_conf[i].setWidth(width);
|
||||
+
|
||||
+ sprintf(rclass, "Bbappconf.%d.Height",i+1);
|
||||
+ sprintf(rname, "bbappconf.%d.height",i+1);
|
||||
+ if ((XrmGetResource(resource_db, rname,rclass,&value_type, &value))) {
|
||||
+ if (sscanf(value.addr, "%u", &height) != 1) {
|
||||
+ height = -1;
|
||||
+ }
|
||||
+ } else
|
||||
+ height=-1;
|
||||
+ app_conf[i].setHeight(height);
|
||||
+
|
||||
+ sprintf(rclass, "Bbappconf.%d.PositionX",i+1);
|
||||
+ sprintf(rname, "bbappconf.%d.positionX",i+1);
|
||||
+ if ((XrmGetResource(resource_db, rname,rclass,
|
||||
+ &value_type, &value))) {
|
||||
+ if (sscanf(value.addr, "%u", &position_x) != 1) {
|
||||
+ position_x = -1111;
|
||||
+ }
|
||||
+ } else
|
||||
+ position_x=-1111;
|
||||
+ app_conf[i].setPositionX(position_x);
|
||||
+
|
||||
+ sprintf(rclass, "Bbappconf.%d.PositionY",i+1);
|
||||
+ sprintf(rname, "bbappconf.%d.positionY",i+1);
|
||||
+ if ((XrmGetResource(resource_db, rname,rclass,
|
||||
+ &value_type, &value))) {
|
||||
+ if (sscanf(value.addr, "%u", &position_y) != 1) {
|
||||
+ position_y = -1111;
|
||||
+ }
|
||||
+ } else
|
||||
+ position_y=-1111;
|
||||
+ app_conf[i].setPositionY(position_y);
|
||||
|
||||
}
|
||||
}
|
29
misc/bbappconf/patches/patch-be
Normal file
29
misc/bbappconf/patches/patch-be
Normal file
|
@ -0,0 +1,29 @@
|
|||
$NetBSD: patch-be,v 1.1 2002/08/05 21:42:34 jschauma Exp $
|
||||
|
||||
--- wminterface.cc.orig Mon Aug 5 17:05:01 2002
|
||||
+++ wminterface.cc Mon Aug 5 17:06:15 2002
|
||||
@@ -285,9 +285,9 @@
|
||||
|
||||
void WMInterface::NETNotifyStartup() {
|
||||
bbtool->setNETInit(); //wm_init=True;
|
||||
- XClearWindow(bbtool->getXDisplay(), bbtool->framewin);
|
||||
+/* XClearWindow(bbtool->getXDisplay(), bbtool->framewin);
|
||||
XMapWindow(bbtool->getXDisplay(), bbtool->framewin);
|
||||
- XMapSubwindows(bbtool->getXDisplay(), bbtool->framewin);
|
||||
+ XMapSubwindows(bbtool->getXDisplay(), bbtool->framewin); */
|
||||
}
|
||||
|
||||
void WMInterface::NETNotifyWindowAdd(Window win,int desktop_nr) {
|
||||
@@ -415,3 +415,12 @@
|
||||
} else if (number_of_desktops<old_number_of_desktops)
|
||||
bbtool->removeDesktopWindow();*/
|
||||
}
|
||||
+
|
||||
+void WMInterface::moveWindow(Window win, int x, int y) {
|
||||
+ XMoveWindow(bbtool->getXDisplay(), win, x, y);
|
||||
+}
|
||||
+
|
||||
+void WMInterface::resizeWindow(Window win, int width, int height) {
|
||||
+ XResizeWindow(bbtool->getXDisplay(), win, width, height);
|
||||
+}
|
||||
+
|
13
misc/bbappconf/patches/patch-bf
Normal file
13
misc/bbappconf/patches/patch-bf
Normal file
|
@ -0,0 +1,13 @@
|
|||
$NetBSD: patch-bf,v 1.1 2002/08/05 21:42:34 jschauma Exp $
|
||||
|
||||
--- wminterface.hh.orig Mon Aug 5 17:06:39 2002
|
||||
+++ wminterface.hh Mon Aug 5 17:07:13 2002
|
||||
@@ -53,6 +53,8 @@
|
||||
int getAttributes(Window);
|
||||
void changeIconState(Window);
|
||||
void windowAttributeChange(Window);
|
||||
+ void moveWindow(Window,int,int);
|
||||
+ void resizeWindow(Window,int,int);
|
||||
|
||||
int getNumberOfDesktops();
|
||||
int getCurrentDesktop();
|
Loading…
Reference in a new issue