[MPlayer-cvslog] r25647 - in trunk: gui/wm/wsxdnd.c vidix/sis_regs.h
diego
subversion at mplayerhq.hu
Tue Jan 8 00:43:10 CET 2008
Author: diego
Date: Tue Jan 8 00:43:10 2008
New Revision: 25647
Log:
Fix illegal identifier, names starting with _ and uppercase are reserved.
Modified:
trunk/gui/wm/wsxdnd.c
trunk/vidix/sis_regs.h
Modified: trunk/gui/wm/wsxdnd.c
==============================================================================
--- trunk/gui/wm/wsxdnd.c (original)
+++ trunk/gui/wm/wsxdnd.c Tue Jan 8 00:43:10 2008
@@ -16,42 +16,42 @@
#define XDND_VERSION 3L
-Atom _XA_XdndAware;
-Atom _XA_XdndEnter;
-Atom _XA_XdndLeave;
-Atom _XA_XdndDrop;
-Atom _XA_XdndPosition;
-Atom _XA_XdndStatus;
-Atom _XA_XdndActionCopy;
-Atom _XA_XdndSelection;
-Atom _XA_XdndFinished;
-Atom _XA_XdndTypeList;
+Atom XA_XdndAware;
+Atom XA_XdndEnter;
+Atom XA_XdndLeave;
+Atom XA_XdndDrop;
+Atom XA_XdndPosition;
+Atom XA_XdndStatus;
+Atom XA_XdndActionCopy;
+Atom XA_XdndSelection;
+Atom XA_XdndFinished;
+Atom XA_XdndTypeList;
Atom atom_support;
void wsXDNDInitialize(void)
{
- _XA_XdndAware = XInternAtom(wsDisplay, "XdndAware", False);
- _XA_XdndEnter = XInternAtom(wsDisplay, "XdndEnter", False);
- _XA_XdndLeave = XInternAtom(wsDisplay, "XdndLeave", False);
- _XA_XdndDrop = XInternAtom(wsDisplay, "XdndDrop", False);
- _XA_XdndPosition = XInternAtom(wsDisplay, "XdndPosition", False);
- _XA_XdndStatus = XInternAtom(wsDisplay, "XdndStatus", False);
- _XA_XdndActionCopy = XInternAtom(wsDisplay, "XdndActionCopy", False);
- _XA_XdndSelection = XInternAtom(wsDisplay, "XdndSelection", False);
- _XA_XdndFinished = XInternAtom(wsDisplay, "XdndFinished", False);
- _XA_XdndTypeList = XInternAtom(wsDisplay, "XdndTypeList", False);
+ XA_XdndAware = XInternAtom(wsDisplay, "XdndAware", False);
+ XA_XdndEnter = XInternAtom(wsDisplay, "XdndEnter", False);
+ XA_XdndLeave = XInternAtom(wsDisplay, "XdndLeave", False);
+ XA_XdndDrop = XInternAtom(wsDisplay, "XdndDrop", False);
+ XA_XdndPosition = XInternAtom(wsDisplay, "XdndPosition", False);
+ XA_XdndStatus = XInternAtom(wsDisplay, "XdndStatus", False);
+ XA_XdndActionCopy = XInternAtom(wsDisplay, "XdndActionCopy", False);
+ XA_XdndSelection = XInternAtom(wsDisplay, "XdndSelection", False);
+ XA_XdndFinished = XInternAtom(wsDisplay, "XdndFinished", False);
+ XA_XdndTypeList = XInternAtom(wsDisplay, "XdndTypeList", False);
}
void wsXDNDMakeAwareness(wsTWindow* window) {
long int xdnd_version = XDND_VERSION;
- XChangeProperty (wsDisplay, window->WindowID, _XA_XdndAware, XA_ATOM,
+ XChangeProperty (wsDisplay, window->WindowID, XA_XdndAware, XA_ATOM,
32, PropModeAppend, (char *)&xdnd_version, 1);
}
void wsXDNDClearAwareness(wsTWindow* window) {
- XDeleteProperty (wsDisplay, window->WindowID, _XA_XdndAware);
+ XDeleteProperty (wsDisplay, window->WindowID, XA_XdndAware);
}
#define MAX_DND_FILES 64
@@ -65,7 +65,7 @@ wsXDNDProcessSelection(wsTWindow* wnd, X
char * delme;
XEvent xevent;
- Window selowner = XGetSelectionOwner(wsDisplay,_XA_XdndSelection);
+ Window selowner = XGetSelectionOwner(wsDisplay,XA_XdndSelection);
XGetWindowProperty(wsDisplay, event->xselection.requestor,
event->xselection.property,
@@ -77,7 +77,7 @@ wsXDNDProcessSelection(wsTWindow* wnd, X
xevent.xany.type = ClientMessage;
xevent.xany.display = wsDisplay;
xevent.xclient.window = selowner;
- xevent.xclient.message_type = _XA_XdndFinished;
+ xevent.xclient.message_type = XA_XdndFinished;
xevent.xclient.format = 32;
XDND_FINISHED_TARGET_WIN(&xevent) = wnd->WindowID;
XSendEvent(wsDisplay, selowner, 0, 0, &xevent);
@@ -142,7 +142,7 @@ wsXDNDProcessClientMessage(wsTWindow* wn
XFree(name);
}*/
- if (event->message_type == _XA_XdndEnter) {
+ if (event->message_type == XA_XdndEnter) {
Atom ok = XInternAtom(wsDisplay, "text/uri-list", False);
atom_support = None;
if ((event->data.l[1] & 1) == 0){
@@ -166,7 +166,7 @@ wsXDNDProcessClientMessage(wsTWindow* wn
/* while there is data left...*/
while(ret_left && atom_support == None){
- XGetWindowProperty(wsDisplay,event->data.l[0],_XA_XdndTypeList,
+ XGetWindowProperty(wsDisplay,event->data.l[0],XA_XdndTypeList,
offset,256,False,XA_ATOM,&ret_type,
&ret_format,&ret_items,&ret_left,
(unsigned char**)&ret_buff);
@@ -194,23 +194,23 @@ wsXDNDProcessClientMessage(wsTWindow* wn
return True;
}
- if (event->message_type == _XA_XdndLeave) {
+ if (event->message_type == XA_XdndLeave) {
return True;
}
- if (event->message_type == _XA_XdndDrop) {
- if (event->data.l[0] != XGetSelectionOwner(wsDisplay, _XA_XdndSelection)){
+ if (event->message_type == XA_XdndDrop) {
+ if (event->data.l[0] != XGetSelectionOwner(wsDisplay, XA_XdndSelection)){
puts("Wierd selection owner... QT?");
}
if (atom_support != None) {
- XConvertSelection(wsDisplay, _XA_XdndSelection, atom_support,
- _XA_XdndSelection, event->window,
+ XConvertSelection(wsDisplay, XA_XdndSelection, atom_support,
+ XA_XdndSelection, event->window,
CurrentTime);
}
return True;
}
- if (event->message_type == _XA_XdndPosition) {
+ if (event->message_type == XA_XdndPosition) {
Window srcwin = event->data.l[0];
if (atom_support == None){
return True;
@@ -223,7 +223,7 @@ wsXDNDProcessClientMessage(wsTWindow* wn
xevent.xany.type = ClientMessage;
xevent.xany.display = wsDisplay;
xevent.xclient.window = srcwin;
- xevent.xclient.message_type = _XA_XdndStatus;
+ xevent.xclient.message_type = XA_XdndStatus;
xevent.xclient.format = 32;
XDND_STATUS_TARGET_WIN (&xevent) = event->window;
@@ -231,7 +231,7 @@ wsXDNDProcessClientMessage(wsTWindow* wn
XDND_STATUS_WANT_POSITION_SET(&xevent, True);
/* actually need smth real here */
XDND_STATUS_RECT_SET(&xevent, 0, 0, 1024,768);
- XDND_STATUS_ACTION(&xevent) = _XA_XdndActionCopy;
+ XDND_STATUS_ACTION(&xevent) = XA_XdndActionCopy;
XSendEvent(wsDisplay, srcwin, 0, 0, &xevent);
}
Modified: trunk/vidix/sis_regs.h
==============================================================================
--- trunk/vidix/sis_regs.h (original)
+++ trunk/vidix/sis_regs.h Tue Jan 8 00:43:10 2008
@@ -383,16 +383,16 @@
* so users with different desktop sizes can keep
* captured data off the desktop
*/
-#define _VINWID 704
-#define _VINHGT _VINHGT_NTSC
-#define _VINHGT_NTSC 240
-#define _VINHGT_PAL 290
-#define _VIN_WINDOW (704 * 291 * 2)
-#define _VBI_WINDOW (704 * 64 * 2)
+#define VINWID 704
+#define VINHGT VINHGT_NTSC
+#define VINHGT_NTSC 240
+#define VINHGT_PAL 290
+#define VIN_WINDOW (704 * 291 * 2)
+#define VBI_WINDOW (704 * 64 * 2)
-#define _VIN_FIELD_EVEN 1
-#define _VIN_FIELD_ODD 2
-#define _VIN_FIELD_BOTH 4
+#define VIN_FIELD_EVEN 1
+#define VIN_FIELD_ODD 2
+#define VIN_FIELD_BOTH 4
/* i2c registers (TW; not on 300/310/325 series) */
More information about the MPlayer-cvslog
mailing list