ViewVC Help
View File | Revision Log | Show Annotations | Download File
/cvs/rxvt-unicode/src/init.C
(Generate patch)

Comparing rxvt-unicode/src/init.C (file contents):
Revision 1.114 by root, Sun Feb 20 00:09:25 2005 UTC vs.
Revision 1.117 by root, Thu Jul 7 19:37:47 2005 UTC

185 "INCR", 185 "INCR",
186 "WM_PROTOCOLS", 186 "WM_PROTOCOLS",
187 "WM_DELETE_WINDOW", 187 "WM_DELETE_WINDOW",
188 "CLIPBOARD", 188 "CLIPBOARD",
189#if ENABLE_FRILLS 189#if ENABLE_FRILLS
190 "_MOTIF_WM_HINTS",
191#endif
192#if ENABLE_EWMH
190 "_NET_WM_PID", 193 "_NET_WM_PID",
191 "_MOTIF_WM_HINTS",
192 "_NET_WM_NAME", 194 "_NET_WM_NAME",
193 "_NET_WM_ICON_NAME", 195 "_NET_WM_ICON_NAME",
196 "_NET_WM_PING",
194#endif 197#endif
195#if USE_XIM 198#if USE_XIM
196 "WM_LOCALE_NAME", 199 "WM_LOCALE_NAME",
197#endif 200#endif
198#ifdef TRANSPARENT 201#ifdef TRANSPARENT
341 if ((rs[Rs_display_name] = getenv ("DISPLAY")) == NULL) 344 if ((rs[Rs_display_name] = getenv ("DISPLAY")) == NULL)
342 rs[Rs_display_name] = ":0"; 345 rs[Rs_display_name] = ":0";
343 346
344 get_options (r_argc, r_argv); 347 get_options (r_argc, r_argv);
345 348
346#ifdef LOCAL_X_IS_UNIX
347 if (rs[Rs_display_name][0] == ':')
348 {
349 val = rxvt_malloc (5 + strlen (rs[Rs_display_name]));
350 strcpy (val, "unix");
351 strcat (val, rs[Rs_display_name]);
352 display = displays.get (val);
353 free (val);
354 }
355#endif
356
357 if (!display
358 && ! (display = displays.get (rs[Rs_display_name]))) 349 if (!(display = displays.get (rs[Rs_display_name])))
359 rxvt_fatal ("can't open display %s, aborting.\n", rs[Rs_display_name]); 350 rxvt_fatal ("can't open display %s, aborting.\n", rs[Rs_display_name]);
360 351
361 extract_resources (); 352 extract_resources ();
362 free (r_argv); 353 free (r_argv);
363 354
967 mwmhints.flags = MWM_HINTS_DECORATIONS; 958 mwmhints.flags = MWM_HINTS_DECORATIONS;
968 mwmhints.decorations = 0; 959 mwmhints.decorations = 0;
969 } 960 }
970 } 961 }
971 else 962 else
972 {
973 mwmhints.flags = 0; 963 mwmhints.flags = 0;
974 }
975#endif 964#endif
976 965
977 /* grab colors before netscape does */ 966 /* grab colors before netscape does */
978 Get_Colours (); 967 Get_Colours ();
979 968
1033 wmHint.flags = InputHint | StateHint | WindowGroupHint; 1022 wmHint.flags = InputHint | StateHint | WindowGroupHint;
1034 wmHint.input = True; 1023 wmHint.input = True;
1035 wmHint.initial_state = options & Opt_iconic ? IconicState : NormalState; 1024 wmHint.initial_state = options & Opt_iconic ? IconicState : NormalState;
1036 wmHint.window_group = top; 1025 wmHint.window_group = top;
1037 1026
1038 XSetWMProperties (disp, top, NULL, NULL, 1027 XmbSetWMProperties (disp, top, NULL, NULL, (char **)argv, argc,
1039 (char **)argv, argc, &szHint, &wmHint, &classHint); 1028 &szHint, &wmHint, &classHint);
1040 1029
1041 /* Enable delete window protocol */ 1030 Atom protocols[] = {
1042 XSetWMProtocols (disp, top, &xa[XA_WM_DELETE_WINDOW], 1); 1031 xa[XA_WM_DELETE_WINDOW],
1032#if ENABLE_EWMH
1033 xa[XA_NET_WM_PING],
1034#endif
1035 };
1043 1036
1044#if ENABLE_FRILLS 1037 XSetWMProtocols (disp, top, protocols, sizeof (protocols) / sizeof (protocols[0]));
1038
1039#if ENABLE_EWMH
1045 long pid = getpid (); 1040 long pid = getpid ();
1046 1041
1047 XChangeProperty (disp, top, 1042 XChangeProperty (disp, top,
1048 xa[XA_NET_WM_PID], XA_CARDINAL, 32, 1043 xa[XA_NET_WM_PID], XA_CARDINAL, 32,
1049 PropModeReplace, (unsigned char *)&pid, 1); 1044 PropModeReplace, (unsigned char *)&pid, 1);
1045
1046 // _NET_WM_WINDOW_TYPE is NORMAL, which is the default
1050#endif 1047#endif
1051 1048
1052 XSelectInput (disp, top, 1049 XSelectInput (disp, top,
1053 KeyPressMask 1050 KeyPressMask
1054#if (MOUSE_WHEEL && MOUSE_SLIP_WHEELING) || ENABLE_FRILLS || ISO_14755 1051#if (MOUSE_WHEEL && MOUSE_SLIP_WHEELING) || ENABLE_FRILLS || ISO_14755

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines