comparison src/w32fns.c @ 25235:98c67187cd6b

(x_set_icon_type): Support setting frame icons.
author Geoff Voelker <voelker@cs.washington.edu>
date Tue, 10 Aug 1999 17:32:59 +0000
parents d89aa269255d
children 64b742df49ca
comparison
equal deleted inserted replaced
25234:17336b4fc693 25235:98c67187cd6b
2043 void 2043 void
2044 x_set_icon_type (f, arg, oldval) 2044 x_set_icon_type (f, arg, oldval)
2045 struct frame *f; 2045 struct frame *f;
2046 Lisp_Object arg, oldval; 2046 Lisp_Object arg, oldval;
2047 { 2047 {
2048 #if 0
2049 Lisp_Object tem;
2050 int result; 2048 int result;
2051 2049
2052 if (STRINGP (arg)) 2050 if (NILP (arg) && NILP (oldval))
2053 {
2054 if (STRINGP (oldval) && EQ (Fstring_equal (oldval, arg), Qt))
2055 return;
2056 }
2057 else if (!STRINGP (oldval) && EQ (oldval, Qnil) == EQ (arg, Qnil))
2058 return; 2051 return;
2059 2052
2053 if (STRINGP (arg) && STRINGP (oldval)
2054 && EQ (Fstring_equal (oldval, arg), Qt))
2055 return;
2056
2057 if (SYMBOLP (arg) && SYMBOLP (oldval) && EQ (arg, oldval))
2058 return;
2059
2060 BLOCK_INPUT; 2060 BLOCK_INPUT;
2061 if (NILP (arg)) 2061
2062 result = x_text_icon (f, 2062 result = x_bitmap_icon (f, arg);
2063 (char *) XSTRING ((!NILP (f->icon_name)
2064 ? f->icon_name
2065 : f->name))->data);
2066 else
2067 result = x_bitmap_icon (f, arg);
2068
2069 if (result) 2063 if (result)
2070 { 2064 {
2071 UNBLOCK_INPUT; 2065 UNBLOCK_INPUT;
2072 error ("No icon window available"); 2066 error ("No icon window available");
2073 } 2067 }
2074 2068
2075 /* If the window was unmapped (and its icon was mapped),
2076 the new icon is not mapped, so map the window in its stead. */
2077 if (FRAME_VISIBLE_P (f))
2078 {
2079 #ifdef USE_X_TOOLKIT
2080 XtPopup (f->output_data.w32->widget, XtGrabNone);
2081 #endif
2082 XMapWindow (FRAME_W32_DISPLAY (f), FRAME_W32_WINDOW (f));
2083 }
2084
2085 XFlush (FRAME_W32_DISPLAY (f));
2086 UNBLOCK_INPUT; 2069 UNBLOCK_INPUT;
2087 #endif
2088 } 2070 }
2089 2071
2090 /* Return non-nil if frame F wants a bitmap icon. */ 2072 /* Return non-nil if frame F wants a bitmap icon. */
2091 2073
2092 Lisp_Object 2074 Lisp_Object