Changeset 4242

Show
Ignore:
Timestamp:
09/06/08 17:25:38 (3 months ago)
Author:
miyoshi
Message:

* w32select.c (create_owner): Request the message thread to create
a window. Refer to tiket:395. Thanks to the anonymous
contributor who made 'clipbd.patch'.

* mw32term.h (WM_EMACS_CREATE_CLPBD): New macro. Refer to
tiket:395. Thanks to the anonymous contributor who made
'clipbd.patch'.
(WM_EMACS_CREATE_CLPBD_REPLY): Ditto.

* mw32fns.c (mw32m_track_popup_menu): New function. Refer to
tiket:395. Thanks to the anonymous contributor who made
'clipbd.patch'.
(mw32_WndProc<WM_EMACS_CREATE_CLPBD>): Call mw32m_create_clpbd().
Refer to tiket:395. Thanks to the anonymous contributor who made
'clipbd.patch'.

Files:

Legend:

Unmodified
Added
Removed
Modified
Copied
Moved
  • trunk/src/ChangeLog.Meadow

    r4241 r4242  
     12008-09-06  MIYOSHI Masanori  <miyoshi@meadowy.org> 
     2 
     3        * w32select.c (create_owner): Request the message thread to create 
     4        a window.  Refer to tiket:395.  Thanks to the anonymous 
     5        contributor who made 'clipbd.patch'. 
     6 
     7        * mw32term.h (WM_EMACS_CREATE_CLPBD): New macro.  Refer to 
     8        tiket:395.  Thanks to the anonymous contributor who made 
     9        'clipbd.patch'. 
     10        (WM_EMACS_CREATE_CLPBD_REPLY): Ditto. 
     11 
     12        * mw32fns.c (mw32m_track_popup_menu): New function. Refer to 
     13        tiket:395.  Thanks to the anonymous contributor who made 
     14        'clipbd.patch'. 
     15        (mw32_WndProc<WM_EMACS_CREATE_CLPBD>): Call mw32m_create_clpbd(). 
     16        Refer to tiket:395.  Thanks to the anonymous contributor who made 
     17        'clipbd.patch'. 
     18 
    1192008-09-06  Masayuki FUJII  <boochang@m4.kcn.ne.jp> 
    220 
  • trunk/src/mw32fns.c

    r4240 r4242  
    16181618                              (WPARAM) 0, (LPARAM) 0); 
    16191619  return; 
     1620} 
     1621 
     1622static void 
     1623mw32m_create_clpbd (void) 
     1624{ 
     1625  static const char CLASSNAME[] = "Emacs Clipboard"; 
     1626  HWND hwnd; 
     1627  
     1628  hwnd = CreateWindow (CLASSNAME, CLASSNAME, 0, 0, 0, 0, 0, NULL, NULL, 
     1629                       NULL, NULL); 
     1630 
     1631  POST_THREAD_INFORM_MESSAGE (main_thread_id, WM_EMACS_CREATE_CLPBD_REPLY, 
     1632                              (WPARAM) hwnd, (LPARAM) 0); 
    16201633} 
    16211634 
     
    27072720    case WM_EMACS_UPDATE_ALPHA: 
    27082721      mw32_update_frame_alpha ((struct frame *) wParam); 
     2722      break; 
     2723 
     2724    case WM_EMACS_CREATE_CLPBD: 
     2725      mw32m_create_clpbd (); 
    27092726      break; 
    27102727 
  • trunk/src/mw32term.h

    r4192 r4242  
    787787#define WM_EMACS_KEYSTROKE                      (WM_USER+2015) 
    788788#define WM_EMACS_FLUSH_MESSAGE                  (WM_USER+2016) 
     789#define WM_EMACS_CREATE_CLPBD                   (WM_USER+2017) 
    789790/* to report "switch-buffer" event by himi */ 
    790791#define WM_IME_REPORT     0x0280 
     
    854855#define WM_EMACS_UNREGISTER_HOT_KEY             (WM_USER+2057) 
    855856#define WM_EMACS_CREATE_TIP_FRAME_REPLY         (WM_USER+2058) 
     857#define WM_EMACS_CREATE_CLPBD_REPLY             (WM_USER+2059) 
    856858 
    857859/* This method guarantee message reachability. 
  • trunk/src/w32select.c

    r4235 r4242  
    502502  RegisterClass (&wc); 
    503503 
     504#ifndef MEADOW 
    504505  return CreateWindow (CLASSNAME, CLASSNAME, 0, 0, 0, 0, 0, NULL, NULL, 
    505506                       NULL, NULL); 
     507#else 
     508  if (msg_thread_id) 
     509    { 
     510      MSG msg; 
     511       
     512      SEND_MSGTHREAD_INFORM_MESSAGE (WM_EMACS_CREATE_CLPBD, 
     513                                     (WPARAM) NULL, (LPARAM) NULL); 
     514      WAIT_REPLY_MESSAGE (&msg, WM_EMACS_CREATE_CLPBD_REPLY); 
     515 
     516      return (HWND) msg.wParam; 
     517    } 
     518  else 
     519    return NULL; 
     520#endif 
    506521} 
    507522