Index: MUSHclient.rc =================================================================== RCS file: /cvs/mushclient/MUSHclient.rc,v retrieving revision 1.228 retrieving revision 1.229 diff -c -r1.228 -r1.229 *** MUSHclient.rc 12 Aug 2008 01:29:06 -0000 1.228 --- MUSHclient.rc 18 Sep 2008 23:22:23 -0000 1.229 *************** *** 75,82 **** // VS_VERSION_INFO VERSIONINFO ! FILEVERSION 4,0,36,0 ! PRODUCTVERSION 4,0,36,0 FILEFLAGSMASK 0x3fL #ifdef _DEBUG FILEFLAGS 0x1L --- 75,82 ---- // VS_VERSION_INFO VERSIONINFO ! FILEVERSION 4,0,37,0 ! PRODUCTVERSION 4,0,37,0 FILEFLAGSMASK 0x3fL #ifdef _DEBUG FILEFLAGS 0x1L *************** *** 94,107 **** VALUE "Comments", "MUSHclient - a client program for playing MUD games\0" VALUE "CompanyName", "Gammon Software Solutions\0" VALUE "FileDescription", "MUSHclient\0" ! VALUE "FileVersion", "4.36\0" VALUE "InternalName", "MUSHCLIENT\0" VALUE "LegalCopyright", "Copyright © 2008 Gammon Software Solutions\0" VALUE "LegalTrademarks", "\0" VALUE "OriginalFilename", "MUSHCLIENT.EXE\0" VALUE "PrivateBuild", "\0" VALUE "ProductName", "MUSHclient\0" ! VALUE "ProductVersion", "4.36\0" VALUE "SpecialBuild", "\0" END END --- 94,107 ---- VALUE "Comments", "MUSHclient - a client program for playing MUD games\0" VALUE "CompanyName", "Gammon Software Solutions\0" VALUE "FileDescription", "MUSHclient\0" ! VALUE "FileVersion", "4.37\0" VALUE "InternalName", "MUSHCLIENT\0" VALUE "LegalCopyright", "Copyright © 2008 Gammon Software Solutions\0" VALUE "LegalTrademarks", "\0" VALUE "OriginalFilename", "MUSHCLIENT.EXE\0" VALUE "PrivateBuild", "\0" VALUE "ProductName", "MUSHclient\0" ! VALUE "ProductVersion", "4.37\0" VALUE "SpecialBuild", "\0" END END Index: OtherTypes.h =================================================================== RCS file: /cvs/mushclient/OtherTypes.h,v retrieving revision 1.102 retrieving revision 1.103 diff -c -r1.102 -r1.103 *** OtherTypes.h 26 Aug 2008 05:23:14 -0000 1.102 --- OtherTypes.h 18 Sep 2008 23:22:23 -0000 1.103 *************** *** 1174,1179 **** --- 1174,1183 ---- bool m_bTemporarilyHide; // no room right now HotspotMap m_Hotspots; // where we can click with the mouse + // where we last did things: + CPoint m_last_mouseposition; + long m_last_mouse_update; + string m_sMouseOverHotspot; // last hotspot we moused over string m_sMouseDownHotspot; // last hotspot we mouse clicked in *************** *** 1314,1319 **** --- 1318,1325 ---- long Left, long Top, long Right, long Bottom, short Mode, double Opacity, long SrcLeft, long SrcTop, long SrcRight, long SrcBottom); + + CString Menu(long Left, long Top, LPCTSTR Items, CMUSHView* pView); }; Index: doc.cpp =================================================================== RCS file: /cvs/mushclient/doc.cpp,v retrieving revision 1.257 retrieving revision 1.258 diff -c -r1.257 -r1.258 *** doc.cpp 26 Aug 2008 05:23:14 -0000 1.257 --- doc.cpp 18 Sep 2008 23:22:23 -0000 1.258 *************** *** 554,559 **** --- 554,561 ---- DISP_FUNCTION(CMUSHclientDoc, "FilterPixel", FilterPixel, VT_I4, VTS_I4 VTS_I2 VTS_R8) DISP_FUNCTION(CMUSHclientDoc, "BlendPixel", BlendPixel, VT_I4, VTS_I4 VTS_I4 VTS_I2 VTS_R8) DISP_FUNCTION(CMUSHclientDoc, "WindowMergeImageAlpha", WindowMergeImageAlpha, VT_I4, VTS_BSTR VTS_BSTR VTS_BSTR VTS_I4 VTS_I4 VTS_I4 VTS_I4 VTS_I2 VTS_R8 VTS_I4 VTS_I4 VTS_I4 VTS_I4) + DISP_FUNCTION(CMUSHclientDoc, "WindowDelete", WindowDelete, VT_I4, VTS_BSTR) + DISP_FUNCTION(CMUSHclientDoc, "WindowMenu", WindowMenu, VT_BSTR, VTS_BSTR VTS_I4 VTS_I4 VTS_BSTR) DISP_PROPERTY_PARAM(CMUSHclientDoc, "NormalColour", GetNormalColour, SetNormalColour, VT_I4, VTS_I2) DISP_PROPERTY_PARAM(CMUSHclientDoc, "BoldColour", GetBoldColour, SetBoldColour, VT_I4, VTS_I2) DISP_PROPERTY_PARAM(CMUSHclientDoc, "CustomColourText", GetCustomColourText, SetCustomColourText, VT_I4, VTS_I2) Index: doc.h =================================================================== RCS file: /cvs/mushclient/doc.h,v retrieving revision 1.274 retrieving revision 1.275 diff -c -r1.274 -r1.275 *** doc.h 26 Aug 2008 05:23:14 -0000 1.274 --- doc.h 18 Sep 2008 23:22:23 -0000 1.275 *************** *** 21,28 **** // New versions - things to change ! #define THISVERSION 436 // Step 1. ! const CString MUSHCLIENT_VERSION = "4.36"; // Step 2. // Step 3. Don't forget VERSION resource in Resources tab // Step 4. Remember: README.TXT --- 21,28 ---- // New versions - things to change ! #define THISVERSION 437 // Step 1. ! const CString MUSHCLIENT_VERSION = "4.37"; // Step 2. // Step 3. Don't forget VERSION resource in Resources tab // Step 4. Remember: README.TXT *************** *** 2512,2517 **** --- 2512,2519 ---- afx_msg long FilterPixel(long Pixel, short Operation, double Options); afx_msg long BlendPixel(long Blend, long Base, short Mode, double Opacity); afx_msg long WindowMergeImageAlpha(LPCTSTR Name, LPCTSTR ImageId, LPCTSTR MaskId, long Left, long Top, long Right, long Bottom, short Mode, double Opacity, long SrcLeft, long SrcTop, long SrcRight, long SrcBottom); + afx_msg long WindowDelete(LPCTSTR Name); + afx_msg BSTR WindowMenu(LPCTSTR Name, long Left, long Top, LPCTSTR Items); afx_msg long GetNormalColour(short WhichColour); afx_msg void SetNormalColour(short WhichColour, long nNewValue); afx_msg long GetBoldColour(short WhichColour); Index: functionlist.cpp =================================================================== RCS file: /cvs/mushclient/functionlist.cpp,v retrieving revision 1.55 retrieving revision 1.56 diff -c -r1.55 -r1.56 *** functionlist.cpp 26 Aug 2008 05:23:14 -0000 1.55 --- functionlist.cpp 18 Sep 2008 23:22:23 -0000 1.56 *************** *** 353,358 **** --- 353,359 ---- "WindowCircleOp", "WindowCreate", "WindowCreateImage", + "WindowDelete", "WindowDeleteAllHotspots", "WindowDeleteHotspot", "WindowDrawImage", *************** *** 371,376 **** --- 372,378 ---- "WindowLine", "WindowList", "WindowLoadImage", + "WindowMenu", "WindowMergeImageAlpha", "WindowPolygon", "WindowPosition", Index: lua_methods.cpp =================================================================== RCS file: /cvs/mushclient/lua_methods.cpp,v retrieving revision 1.114 retrieving revision 1.115 diff -c -r1.114 -r1.115 *** lua_methods.cpp 26 Aug 2008 05:23:14 -0000 1.114 --- lua_methods.cpp 18 Sep 2008 23:22:23 -0000 1.115 *************** *** 5144,5149 **** --- 5144,5161 ---- } // end of L_WindowCreateImage //---------------------------------------- + // world.WindowDelete + //---------------------------------------- + static int L_WindowDelete (lua_State *L) + { + CMUSHclientDoc *pDoc = doc (L); + lua_pushnumber (L, pDoc->WindowDelete ( + my_checkstring (L, 1) // Name + )); + return 1; // number of result fields + } // end of L_WindowDelete + + //---------------------------------------- // world.WindowDeleteAllHotspots //---------------------------------------- static int L_WindowDeleteAllHotspots (lua_State *L) *************** *** 5435,5440 **** --- 5447,5470 ---- } // end of L_WindowLoadImage //---------------------------------------- + // world.WindowMenu + //---------------------------------------- + static int L_WindowMenu (lua_State *L) + { + BSTR str; + + CMUSHclientDoc *pDoc = doc (L); + str = pDoc->WindowMenu ( + my_checkstring (L, 1), // Name + my_checknumber (L, 2), // Left + my_checknumber (L, 3), // Top + my_checkstring (L, 4) // Items + ); + + return pushBstr (L, str); // number of result fields + } // end of L_WindowMenu + + //---------------------------------------- // world.WindowMergeImageAlpha //---------------------------------------- static int L_WindowMergeImageAlpha (lua_State *L) *************** *** 5996,6001 **** --- 6026,6032 ---- {"WindowCreate", L_WindowCreate}, {"WindowCreateImage", L_WindowCreateImage}, {"WindowDeleteAllHotspots", L_WindowDeleteAllHotspots}, + {"WindowDelete", L_WindowDelete}, {"WindowDeleteHotspot", L_WindowDeleteHotspot}, {"WindowDrawImage", L_WindowDrawImage}, {"WindowFilter", L_WindowFilter}, *************** *** 6014,6019 **** --- 6045,6051 ---- {"WindowLine", L_WindowLine}, {"WindowList", L_WindowList}, {"WindowLoadImage", L_WindowLoadImage}, + {"WindowMenu", L_WindowMenu}, {"WindowMergeImageAlpha", L_WindowMergeImageAlpha}, {"WindowPolygon", L_WindowPolygon}, {"WindowPosition", L_WindowPosition}, Index: lua_scripting.cpp =================================================================== RCS file: /cvs/mushclient/lua_scripting.cpp,v retrieving revision 1.43 retrieving revision 1.44 diff -c -r1.43 -r1.44 *** lua_scripting.cpp 21 Jun 2008 04:43:53 -0000 1.43 --- lua_scripting.cpp 18 Sep 2008 23:22:23 -0000 1.44 *************** *** 135,141 **** } // end of BuildLuaFunctions ! // for world completion, find all entries in the following tables static void BuildLuaTables (lua_State * L) { const char * table_names [] = { --- 135,141 ---- } // end of BuildLuaFunctions ! // for word completion, find all entries in the following tables static void BuildLuaTables (lua_State * L) { const char * table_names [] = { Index: methods.cpp =================================================================== RCS file: /cvs/mushclient/methods.cpp,v retrieving revision 1.252 retrieving revision 1.253 diff -c -r1.252 -r1.253 *** methods.cpp 26 Aug 2008 05:23:14 -0000 1.252 --- methods.cpp 18 Sep 2008 23:22:23 -0000 1.253 *************** *** 4258,4263 **** --- 4258,4264 ---- { 279, "Text rectangle - outside style" }, { 280, "Output window client height" }, { 281, "Output window client width" }, + { 282, "Text rectangle - border colour" }, *************** *** 4863,4868 **** --- 4864,4871 ---- } break; + case 282: SetUpVariantLong (vaResult, m_TextRectangleBorderColour); break; + case 301: if (m_tConnectTime.GetTime ()) // only if non-zero, otherwise return empty SetUpVariantDate (vaResult, COleDateTime (m_tConnectTime.GetTime ())); *************** *** 12621,12626 **** --- 12624,12631 ---- Position, Flags, BackgroundColour); + UpdateAllViews (NULL); + return eOK; } // end of CMUSHclientDoc::WindowCreate *************** *** 12699,12705 **** MiniWindowMapIterator it = m_MiniWindows.find (Name); if (it == m_MiniWindows.end ()) ! return -1; return it->second->Font (FontId, FontName, Size, --- 12704,12710 ---- MiniWindowMapIterator it = m_MiniWindows.find (Name); if (it == m_MiniWindows.end ()) ! return eNoSuchWindow; return it->second->Font (FontId, FontName, Size, *************** *** 13808,13816 **** return eNoSuchWindow; return it->second->MergeImageAlpha (ImageId, MaskId, Left, Top, Right, Bottom, Mode, Opacity, SrcLeft, SrcTop, SrcRight, SrcBottom); ! } // CMUSHclientDoc::WindowMergeImageAlpha /* --- 13813,13862 ---- return eNoSuchWindow; return it->second->MergeImageAlpha (ImageId, MaskId, Left, Top, Right, Bottom, Mode, Opacity, SrcLeft, SrcTop, SrcRight, SrcBottom); ! } // end of CMUSHclientDoc::WindowMergeImageAlpha + long CMUSHclientDoc::WindowDelete(LPCTSTR Name) + { + MiniWindowMapIterator it = m_MiniWindows.find (Name); + + if (it == m_MiniWindows.end ()) + return eNoSuchWindow; + + delete it->second; + + m_MiniWindows.erase (it); + + UpdateAllViews (NULL); + + return eOK; + } // end of CMUSHclientDoc::WindowDelete + + + BSTR CMUSHclientDoc::WindowMenu(LPCTSTR Name, long Left, long Top, LPCTSTR Items) + { + + CString strResult; + + MiniWindowMapIterator it = m_MiniWindows.find (Name); + + CView* pView = NULL; + + for(POSITION pos = GetFirstViewPosition(); pos != NULL; ) + { + pView = GetNextView(pos); + + if (pView->IsKindOf(RUNTIME_CLASS(CMUSHView))) + break; + + } + + if (pView && it != m_MiniWindows.end ()) + strResult = it->second->Menu (Left, Top, Items, (CMUSHView *) pView); + + return strResult.AllocSysString(); + + } /* Index: miniwindow.cpp =================================================================== RCS file: /cvs/mushclient/miniwindow.cpp,v retrieving revision 1.33 retrieving revision 1.34 diff -c -r1.33 -r1.34 *** miniwindow.cpp 29 Aug 2008 03:33:41 -0000 1.33 --- miniwindow.cpp 18 Sep 2008 23:22:23 -0000 1.34 *************** *** 5,12 **** --- 5,14 ---- #include "stdafx.h" #include "MUSHclient.h" #include "doc.h" + #include "MUSHview.h" #include "errors.h" #include "color.h" + #include "mainfrm.h" #define PNG_NO_CONSOLE_IO #include "png.h" *************** *** 17,23 **** m_iWidth (0), m_iHeight (0), m_iPosition (0), m_iFlags (0), m_iBackgroundColour (0), m_bShow (false), ! m_bTemporarilyHide (false) { dc.CreateCompatibleDC(NULL); dc.SetTextAlign (TA_LEFT | TA_TOP); --- 19,26 ---- m_iWidth (0), m_iHeight (0), m_iPosition (0), m_iFlags (0), m_iBackgroundColour (0), m_bShow (false), ! m_bTemporarilyHide (false), ! m_last_mouse_update (0) { dc.CreateCompatibleDC(NULL); dc.SetTextAlign (TA_LEFT | TA_TOP); *************** *** 924,929 **** --- 927,937 ---- case 12: SetUpVariantLong (vaResult, m_rect.right); break; // " case 13: SetUpVariantLong (vaResult, m_rect.bottom); break; // " + case 14: SetUpVariantLong (vaResult, m_last_mouseposition.x); break; // last mouse x position + case 15: SetUpVariantLong (vaResult, m_last_mouseposition.y); break; // last mouse y position + + case 16: SetUpVariantLong (vaResult, m_last_mouse_update); break; // last position update count + default: vaResult.vt = VT_NULL; break; *************** *** 3444,3447 **** --- 3452,3588 ---- return eOK; } // end of CMiniWindow::MergeImageAlpha + + + #define MXP_FIRST_MENU 10000 + #define MXP_MENU_COUNT 30 // number of MXP menu items we support + + static CString strMXP_menu_item [MXP_MENU_COUNT]; + + CString CMiniWindow::Menu(long Left, long Top, LPCTSTR Items, CMUSHView* pView) + { + CString strResult; + + // can't menu if not visible + if (!m_bShow || m_bTemporarilyHide) + return strResult; + + // can't if outside window + if (Left < 0 || Left > m_iWidth || + Top < 0 || Top > m_iHeight) + return strResult; + + // make relative to miniwindow + Left += m_rect.left; + Top += m_rect.top; + + vector v; + + StringToVector (Items, v, "|"); + + int iCount = v.size (); + + // must have at least one item + if (iCount < 1) + return strResult; + + #if 0 // AARRRRRRRRGGGGGGGGGGGHHHHHHHHHHHHHHH!!!!!!!!!!!!!!!!!!! + + // if we are doing this in response to a mouse-down, we have to cancel the + // mouse-down event now, or things get confused + + if (!pView->m_sPreviousMiniWindow.empty ()) + { + CMUSHclientDoc* pDoc = pView->GetDocument(); + + MiniWindowMapIterator it = pDoc->m_MiniWindows.find (pView->m_sPreviousMiniWindow); + + if (it != pDoc->m_MiniWindows.end ()) + { + + CMiniWindow * old_mw = it->second; + + // cancel previous move-down hotspot + if (!old_mw->m_sMouseDownHotspot.empty ()) // HotspotId was used + { + // lookup that HotspotId + HotspotMapIterator it = old_mw->m_Hotspots.find (old_mw->m_sMouseDownHotspot); + + // call CancelMouseDown for that hotspot, if it exists + if (it != old_mw->m_Hotspots.end ()) + { + m_last_mouseup = m_last_mousemove; + pView->Send_Mouse_Event_To_Plugin (old_mw->m_sCallbackPlugin, + it->second->m_sCancelMouseDown, + old_mw->m_sMouseDownHotspot); + } + old_mw->m_sMouseDownHotspot.erase (); // no mouse-down right now + } // we had previous hotspot + + } // previous window still exists + + pView->m_sPreviousMiniWindow.erase (); // no longer have a previous window + ReleaseCapture(); // Release the mouse capture established at + // the beginning of the mouse click. + + } // released mouse in different window + + #endif // AARRRRRRRRGGGGGGGGGGGHHHHHHHHHHHHHHH!!!!!!!!!!!!!!!!!!! + + + + CPoint menupoint (Left, Top); + + CMenu menu; + VERIFY(menu.LoadMenu(IDR_MXP_MENU)); + + CMenu* pPopup = menu.GetSubMenu(0); + ASSERT(pPopup != NULL); + CWnd* pWndPopupOwner = (CWnd *) pView; + + pPopup->DeleteMenu (0, MF_BYPOSITION); // get rid of dummy item + + while (pWndPopupOwner->GetStyle() & WS_CHILD) + pWndPopupOwner = pWndPopupOwner->GetParent(); + + ClientToScreen(pView->m_hWnd, &menupoint); + + int j = 0; + + for (vector::const_iterator i = v.begin (); i != v.end (); i++) + { + CString strItem = i->c_str (); + + if (*i == "-" || *i == "") + pPopup->AppendMenu (MF_SEPARATOR, 0, ""); + else if (strItem.Left (1) == "^") + pPopup->AppendMenu (MF_STRING | MF_GRAYED, 0, strItem.Mid (1)); + else + { + strMXP_menu_item [j] = strItem; + pPopup->AppendMenu (MF_STRING | MF_ENABLED, MXP_FIRST_MENU + j, strItem); + j++; + if (j >= MXP_MENU_COUNT) + break; + } + } + + // without this line the auto-enable always set "no items" to active + Frame.m_bAutoMenuEnable = FALSE; + + int iResult = pPopup->TrackPopupMenu(TPM_LEFTALIGN | TPM_RIGHTBUTTON | TPM_NONOTIFY | TPM_RETURNCMD, + menupoint.x, + menupoint.y, + pWndPopupOwner); + + // put things back how they were + Frame.m_bAutoMenuEnable = TRUE; + + if (iResult > 0) + strResult = strMXP_menu_item [iResult - MXP_FIRST_MENU]; + + return strResult; // will be empty for errors or cancelled + + + } // end of CMiniWindow::Menu Index: mushclient.cnt =================================================================== RCS file: /cvs/mushclient/mushclient.cnt,v retrieving revision 1.57 retrieving revision 1.58 diff -c -r1.57 -r1.58 *** mushclient.cnt 26 Aug 2008 05:23:14 -0000 1.57 --- mushclient.cnt 18 Sep 2008 23:22:23 -0000 1.58 *************** *** 499,504 **** --- 499,505 ---- 3 WindowCircleOp=FNC_WindowCircleOp 3 WindowCreate=FNC_WindowCreate 3 WindowCreateImage=FNC_WindowCreateImage + 3 WindowDelete=FNC_WindowDelete 3 WindowDeleteAllHotspots=FNC_WindowDeleteAllHotspots 3 WindowDeleteHotspot=FNC_WindowDeleteHotspot 3 WindowDrawImage=FNC_WindowDrawImage *************** *** 517,522 **** --- 518,524 ---- 3 WindowLine=FNC_WindowLine 3 WindowList=FNC_WindowList 3 WindowLoadImage=FNC_WindowLoadImage + 3 WindowMenu=FNC_WindowMenu 3 WindowMergeImageAlpha=FNC_WindowMergeImageAlpha 3 WindowPolygon=FNC_WindowPolygon 3 WindowPosition=FNC_WindowPosition Index: mushclient.hlp =================================================================== RCS file: /cvs/mushclient/mushclient.hlp,v retrieving revision 1.102 retrieving revision 1.103 diff -c -r1.102 -r1.103 Binary files /tmp/cvsOL2vUb and /tmp/cvs2OMKUN differ Index: mushclient.odl =================================================================== RCS file: /cvs/mushclient/mushclient.odl,v retrieving revision 1.139 retrieving revision 1.140 diff -c -r1.139 -r1.140 *** mushclient.odl 26 Aug 2008 05:23:14 -0000 1.139 --- mushclient.odl 18 Sep 2008 23:22:38 -0000 1.140 *************** *** 70,83 **** [id(44)] long SetCommand(BSTR Message); [id(45)] BSTR GetNotes(); [id(46)] void SetNotes(BSTR Message); ! [id(370), propget] long NormalColour(short WhichColour); ! [id(370), propput] void NormalColour(short WhichColour, long nNewValue); ! [id(371), propget] long BoldColour(short WhichColour); ! [id(371), propput] void BoldColour(short WhichColour, long nNewValue); ! [id(372), propget] long CustomColourText(short WhichColour); ! [id(372), propput] void CustomColourText(short WhichColour, long nNewValue); ! [id(373), propget] long CustomColourBackground(short WhichColour); ! [id(373), propput] void CustomColourBackground(short WhichColour, long nNewValue); [id(47)] void Redraw(); [id(48)] long ResetTimer(BSTR TimerName); [id(49)] void SetOutputFont(BSTR FontName, short PointSize); --- 70,83 ---- [id(44)] long SetCommand(BSTR Message); [id(45)] BSTR GetNotes(); [id(46)] void SetNotes(BSTR Message); ! [id(372), propget] long NormalColour(short WhichColour); ! [id(372), propput] void NormalColour(short WhichColour, long nNewValue); ! [id(373), propget] long BoldColour(short WhichColour); ! [id(373), propput] void BoldColour(short WhichColour, long nNewValue); ! [id(374), propget] long CustomColourText(short WhichColour); ! [id(374), propput] void CustomColourText(short WhichColour, long nNewValue); ! [id(375), propget] long CustomColourBackground(short WhichColour); ! [id(375), propput] void CustomColourBackground(short WhichColour, long nNewValue); [id(47)] void Redraw(); [id(48)] long ResetTimer(BSTR TimerName); [id(49)] void SetOutputFont(BSTR FontName, short PointSize); *************** *** 401,406 **** --- 401,408 ---- [id(367)] long FilterPixel(long Pixel, short Operation, double Options); [id(368)] long BlendPixel(long Blend, long Base, short Mode, double Opacity); [id(369)] long WindowMergeImageAlpha(BSTR Name, BSTR ImageId, BSTR MaskId, long Left, long Top, long Right, long Bottom, short Mode, double Opacity, long SrcLeft, long SrcTop, long SrcRight, long SrcBottom); + [id(370)] long WindowDelete(BSTR Name); + [id(371)] BSTR WindowMenu(BSTR Name, long Left, long Top, BSTR Items); //}}AFX_ODL_METHOD }; Index: mushview.cpp =================================================================== RCS file: /cvs/mushclient/mushview.cpp,v retrieving revision 1.115 retrieving revision 1.116 diff -c -r1.115 -r1.116 *** mushview.cpp 26 Aug 2008 05:23:14 -0000 1.115 --- mushview.cpp 18 Sep 2008 23:22:38 -0000 1.116 *************** *** 6193,6198 **** --- 6193,6204 ---- } // moved to different window + if (mw) + { + mw->m_last_mouseposition = CPoint (point.x - mw->m_rect.left, point.y - mw->m_rect.top); + mw->m_last_mouse_update++; + } + // here if currently over a miniwindow if (mw && GetCapture () != this) { *************** *** 6303,6308 **** --- 6309,6318 ---- // here if currently over a miniwindow if (mw) { + + mw->m_last_mouseposition = CPoint (point.x - mw->m_rect.left, point.y - mw->m_rect.top); + mw->m_last_mouse_update++; + // now, are we now over a hotspot? if (pHotspot) { *************** *** 6374,6379 **** --- 6384,6392 ---- // here if currently over a miniwindow if (mw) { + + mw->m_last_mouseposition = CPoint (point.x - mw->m_rect.left, point.y - mw->m_rect.top); + mw->m_last_mouse_update++; // if mouse-up outside the current hotspot just cancel previous one // cancel previous mouse-down hotspot (in this miniwindow) Index: install/readme.txt =================================================================== RCS file: /cvs/mushclient/install/readme.txt,v retrieving revision 1.182 retrieving revision 1.183 diff -c -r1.182 -r1.183 *** install/readme.txt 29 Aug 2008 03:35:05 -0000 1.182 --- install/readme.txt 18 Sep 2008 23:22:38 -0000 1.183 *************** *** 1,7 **** ! MUSHclient version 4.36 ======================= ! Friday, 29th August 2008 Author: Nick Gammon Web support: http://www.gammon.com.au/forum/ --- 1,7 ---- ! MUSHclient version 4.37 ======================= ! Friday, 19th September 2008 Author: Nick Gammon Web support: http://www.gammon.com.au/forum/ Index: lua/pairsbykeys.lua =================================================================== RCS file: /cvs/mushclient/lua/pairsbykeys.lua,v retrieving revision 1.2 retrieving revision 1.3 diff -c -r1.2 -r1.3 *** lua/pairsbykeys.lua 7 Sep 2006 07:46:11 -0000 1.2 --- lua/pairsbykeys.lua 18 Sep 2008 23:22:38 -0000 1.3 *************** *** 4,9 **** --- 4,13 ---- -- but sorted into key sequence. -- It does that by copying the table keys into a temporary table and sorting that. + -- If you need to sort keys other than strings, see: + + -- See: http://lua-users.org/wiki/SortedIteration + function pairsByKeys (t, f) local a = {} -- build temporary table of the keys Index: lua/serialize.lua =================================================================== RCS file: /cvs/mushclient/lua/serialize.lua,v retrieving revision 1.4 retrieving revision 1.5 diff -c -r1.4 -r1.5 *** lua/serialize.lua 21 Jul 2007 03:07:23 -0000 1.4 --- lua/serialize.lua 18 Sep 2008 23:22:38 -0000 1.5 *************** *** 109,117 **** local lua_reserved_words = {} for _, v in ipairs ({ ! "and", "break", "do", "else", "elseif", "end", "false", "for", "function", "if", "in", "local", "nil", "not", "or", ! "repeat", "return", "then", "true", "until", "while" }) do lua_reserved_words [v] = true end -- ---------------------------------------------------------- --- 109,117 ---- local lua_reserved_words = {} for _, v in ipairs ({ ! "and", "break", "do", "else", "elseif", "end", "for", "function", "if", "in", "local", "nil", "not", "or", ! "repeat", "return", "then", "until", "while" }) do lua_reserved_words [v] = true end -- ---------------------------------------------------------- *************** *** 142,153 **** -- make the table constructor, and recurse to save its contents - - assert (string.find (name, '^[_%a][_%a%d%.%[%]" ]*$') - and not lua_reserved_words [name], - "Invalid name '" .. name .. "' for table") - - table.insert (out, iname .. " = {}") -- create a new table for k, v in pairs (value) do -- save its fields --- 142,147 ----