terminal->update_begin_hook = 0;
terminal->update_end_hook = 0;
terminal->set_terminal_window_hook = 0;
- terminal->defined_color_hook = 0;
+ /* Don't clear the defined_color_hook, as that makes it impossible
+ to unload or load a theme when some TTY frame is suspended. */
+ /* terminal->defined_color_hook = 0; */
terminal->mouse_position_hook = 0;
terminal->frame_rehighlight_hook = 0;
terminal->frame_raise_lower_hook = 0;
load_color2 (struct frame *f, struct face *face, Lisp_Object name,
enum lface_attribute_index target_index, Emacs_Color *color)
{
- if (FRAME_TERMINAL (f)->defined_color_hook == NULL)
- {
- Lisp_Object frame;
- XSETFRAME (frame, f);
- signal_error ("Unable to load colors for suspended TTY frame", frame);
- }
-
eassert (STRINGP (name));
eassert (target_index == LFACE_FOREGROUND_INDEX
|| target_index == LFACE_BACKGROUND_INDEX
struct frame *f = decode_live_frame (frame);
Emacs_Color cdef1, cdef2;
- if (FRAME_TERMINAL (f)->defined_color_hook == NULL)
- signal_error ("Unable to validate colors for suspended TTY frame", frame);
-
if (!(CONSP (color1) && parse_rgb_list (color1, &cdef1))
&& !(STRINGP (color1)
&& FRAME_TERMINAL (f)->defined_color_hook (f,