[RELEASE_473] Enhance installer.
Fix horizontal scroll bug regarding the folding issue. Add a new behaviour that click on active tab activate the view as current view. git-svn-id: svn://svn.tuxfamily.org/svnroot/notepadplus/repository@99 f5eea248-9336-0410-98b8-ebc06183d4e3
This commit is contained in:
parent
8c0817a0ba
commit
72bb63c88d
|
@ -1,4 +1,4 @@
|
||||||
Notepad++ v4.7.2 fixed bugs and added features (from v4.6) :
|
Notepad++ v4.7.3 fixed bugs and added features (from v4.6) :
|
||||||
|
|
||||||
1. Make the "recovery system" for 3 mandatory xml files (config.xml, langs.xml and stylers.xml) to prevent the fail loading due to the corrupted files.
|
1. Make the "recovery system" for 3 mandatory xml files (config.xml, langs.xml and stylers.xml) to prevent the fail loading due to the corrupted files.
|
||||||
2. Extend plugin capacity - add the Scintilla external lexer capacity.
|
2. Extend plugin capacity - add the Scintilla external lexer capacity.
|
||||||
|
@ -27,5 +27,5 @@ Included plugins :
|
||||||
5. Explorer plugin v1.6.1
|
5. Explorer plugin v1.6.1
|
||||||
6. Hex editor v0.84
|
6. Hex editor v0.84
|
||||||
7. Base64 encoder/decoder v1.2
|
7. Base64 encoder/decoder v1.2
|
||||||
8. FTP_synchronize v0.9.5.1
|
8. FTP_synchronize v0.9.6
|
||||||
9. NppExport v0.2.5.0
|
9. NppExport v0.2.5.0
|
||||||
|
|
|
@ -17,16 +17,16 @@
|
||||||
|
|
||||||
; Define the application name
|
; Define the application name
|
||||||
!define APPNAME "Notepad++"
|
!define APPNAME "Notepad++"
|
||||||
!define APPNAMEANDVERSION "Notepad++ v4.7.2"
|
!define APPNAMEANDVERSION "Notepad++ v4.7.3"
|
||||||
|
|
||||||
!define VERSION_MAJOR 4
|
!define VERSION_MAJOR 4
|
||||||
!define VERSION_MINOR 72
|
!define VERSION_MINOR 73
|
||||||
|
|
||||||
; Main Install settings
|
; Main Install settings
|
||||||
Name "${APPNAMEANDVERSION}"
|
Name "${APPNAMEANDVERSION}"
|
||||||
InstallDir "$PROGRAMFILES\Notepad++"
|
InstallDir "$PROGRAMFILES\Notepad++"
|
||||||
InstallDirRegKey HKLM "Software\${APPNAME}" ""
|
InstallDirRegKey HKLM "Software\${APPNAME}" ""
|
||||||
OutFile "..\bin\npp.4.7.2.Installer.exe"
|
OutFile "..\bin\npp.4.7.3.Installer.exe"
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
@ -328,6 +328,7 @@ GLOBAL_INST:
|
||||||
File "..\bin\stylers.model.xml"
|
File "..\bin\stylers.model.xml"
|
||||||
|
|
||||||
SetOverwrite off
|
SetOverwrite off
|
||||||
|
File /oname=$INSTDIR\langs.xml "..\bin\langs.model.xml"
|
||||||
File "..\bin\contextMenu.xml"
|
File "..\bin\contextMenu.xml"
|
||||||
File "..\bin\shortcuts.xml"
|
File "..\bin\shortcuts.xml"
|
||||||
|
|
||||||
|
|
|
@ -1700,6 +1700,15 @@ BOOL Notepad_plus::notify(SCNotification *notification)
|
||||||
_statusBar.setText((_pEditView->execute(SCI_GETOVERTYPE))?"OVR":"INS", STATUSBAR_TYPING_MODE);
|
_statusBar.setText((_pEditView->execute(SCI_GETOVERTYPE))?"OVR":"INS", STATUSBAR_TYPING_MODE);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
else if (notification->nmhdr.hwndFrom == _mainDocTab.getHSelf())
|
||||||
|
{
|
||||||
|
switchEditViewTo(MAIN_VIEW);
|
||||||
|
}
|
||||||
|
else if (notification->nmhdr.hwndFrom == _subDocTab.getHSelf())
|
||||||
|
{
|
||||||
|
switchEditViewTo(SUB_VIEW);
|
||||||
|
}
|
||||||
|
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -3373,6 +3382,12 @@ void Notepad_plus::command(int id)
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
case IDM_WIKIFAQ:
|
||||||
|
{
|
||||||
|
::ShellExecute(NULL, "open", "http://notepad-plus.wiki.sourceforge.net/FAQ", NULL, NULL, SW_SHOWNORMAL);
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
|
||||||
case IDM_FORUM:
|
case IDM_FORUM:
|
||||||
{
|
{
|
||||||
::ShellExecute(NULL, "open", "http://sourceforge.net/forum/?group_id=95717", NULL, NULL, SW_SHOWNORMAL);
|
::ShellExecute(NULL, "open", "http://sourceforge.net/forum/?group_id=95717", NULL, NULL, SW_SHOWNORMAL);
|
||||||
|
|
|
@ -476,7 +476,8 @@ BEGIN
|
||||||
MENUITEM "Notepad++ Home", IDM_HOMESWEETHOME
|
MENUITEM "Notepad++ Home", IDM_HOMESWEETHOME
|
||||||
MENUITEM "Notepad++ Project Page", IDM_PROJECTPAGE
|
MENUITEM "Notepad++ Project Page", IDM_PROJECTPAGE
|
||||||
MENUITEM "Online help", IDM_ONLINEHELP
|
MENUITEM "Online help", IDM_ONLINEHELP
|
||||||
MENUITEM "Forum", IDM_FORUM
|
MENUITEM "Wiki FAQ", IDM_WIKIFAQ
|
||||||
|
MENUITEM "Forums", IDM_FORUM
|
||||||
MENUITEM "Get more plugins", IDM_PLUGINSHOME
|
MENUITEM "Get more plugins", IDM_PLUGINSHOME
|
||||||
MENUITEM SEPARATOR
|
MENUITEM SEPARATOR
|
||||||
MENUITEM "Update Notepad++", IDM_UPDATE_NPP
|
MENUITEM "Update Notepad++", IDM_UPDATE_NPP
|
||||||
|
|
|
@ -955,6 +955,8 @@ char * ScintillaEditView::activateDocAt(int index)
|
||||||
execute(SCI_SETEOLMODE, _buffers[_currentIndex]._format);
|
execute(SCI_SETEOLMODE, _buffers[_currentIndex]._format);
|
||||||
::SendMessage(_hParent, NPPM_INTERNAL_DOCSWITCHIN, 0, (LPARAM)_hSelf);
|
::SendMessage(_hParent, NPPM_INTERNAL_DOCSWITCHIN, 0, (LPARAM)_hSelf);
|
||||||
|
|
||||||
|
recalcHorizontalScrollbar(); //Update scrollbar after switching file
|
||||||
|
|
||||||
return _buffers[_currentIndex]._fullPathName;
|
return _buffers[_currentIndex]._fullPathName;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -1159,6 +1161,7 @@ void ScintillaEditView::marginClick(int position, int modifiers)
|
||||||
execute(SCI_TOGGLEFOLD, lineClick, 0);
|
execute(SCI_TOGGLEFOLD, lineClick, 0);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
recalcHorizontalScrollbar(); //Update scrollbar after folding
|
||||||
}
|
}
|
||||||
|
|
||||||
void ScintillaEditView::expand(int &line, bool doExpand, bool force, int visLevels, int level)
|
void ScintillaEditView::expand(int &line, bool doExpand, bool force, int visLevels, int level)
|
||||||
|
@ -1684,9 +1687,14 @@ void ScintillaEditView::recalcHorizontalScrollbar() {
|
||||||
endLine--;
|
endLine--;
|
||||||
long beginPosition, endPosition;
|
long beginPosition, endPosition;
|
||||||
|
|
||||||
for( int i = startLine ; i <= endLine ; i++ ) { //for all _visible_ lines
|
int visibleLine = 0;
|
||||||
endPosition = execute(SCI_GETLINEENDPOSITION, i); //get character position from begin
|
for( int i = startLine ; i <= endLine ; i++ )
|
||||||
beginPosition = execute(SCI_POSITIONFROMLINE, i); //and end of line
|
{
|
||||||
|
//for all _visible_ lines
|
||||||
|
visibleLine = (int) execute(SCI_DOCLINEFROMVISIBLE, i); //get actual visible line, folding may offset lines
|
||||||
|
endPosition = execute(SCI_GETLINEENDPOSITION, visibleLine); //get character position from begin
|
||||||
|
beginPosition = execute(SCI_POSITIONFROMLINE, visibleLine); //and end of line
|
||||||
|
|
||||||
curLen = execute(SCI_POINTXFROMPOSITION, 0, endPosition) - //Then let Scintilla get pixel width with
|
curLen = execute(SCI_POINTXFROMPOSITION, 0, endPosition) - //Then let Scintilla get pixel width with
|
||||||
execute(SCI_POINTXFROMPOSITION, 0, beginPosition); //current styler
|
execute(SCI_POINTXFROMPOSITION, 0, beginPosition); //current styler
|
||||||
if (maxPixel < curLen) { //If its the largest line yet
|
if (maxPixel < curLen) { //If its the largest line yet
|
||||||
|
@ -1700,4 +1708,6 @@ void ScintillaEditView::recalcHorizontalScrollbar() {
|
||||||
int currentLength = execute(SCI_GETSCROLLWIDTH); //Get current scrollbar size
|
int currentLength = execute(SCI_GETSCROLLWIDTH); //Get current scrollbar size
|
||||||
if (currentLength != maxPixel) //And if it is not the same
|
if (currentLength != maxPixel) //And if it is not the same
|
||||||
execute(SCI_SETSCROLLWIDTH, maxPixel); //update it
|
execute(SCI_SETSCROLLWIDTH, maxPixel); //update it
|
||||||
|
|
||||||
|
::ShowScrollBar(_hSelf, SB_HORZ, TRUE); //Force scrollbar visible to prevent 'twitchy' behaviour
|
||||||
}
|
}
|
|
@ -203,11 +203,10 @@ LRESULT TabBarPlus::runProc(HWND hwnd, UINT Message, WPARAM wParam, LPARAM lPara
|
||||||
}
|
}
|
||||||
|
|
||||||
::CallWindowProc(_tabBarDefaultProc, hwnd, Message, wParam, lParam);
|
::CallWindowProc(_tabBarDefaultProc, hwnd, Message, wParam, lParam);
|
||||||
|
|
||||||
if (wParam == 2)
|
if (wParam == 2)
|
||||||
return TRUE;
|
return TRUE;
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
if (_doDragNDrop)
|
if (_doDragNDrop)
|
||||||
{
|
{
|
||||||
_nSrcTab = _nTabDragged = ::SendMessage(_hSelf, TCM_GETCURSEL, 0, 0);
|
_nSrcTab = _nTabDragged = ::SendMessage(_hSelf, TCM_GETCURSEL, 0, 0);
|
||||||
|
@ -220,11 +219,16 @@ LRESULT TabBarPlus::runProc(HWND hwnd, UINT Message, WPARAM wParam, LPARAM lPara
|
||||||
// Yes, we're beginning to drag, so capture the mouse...
|
// Yes, we're beginning to drag, so capture the mouse...
|
||||||
_isDragging = true;
|
_isDragging = true;
|
||||||
::SetCapture(hwnd);
|
::SetCapture(hwnd);
|
||||||
return TRUE;
|
|
||||||
}
|
}
|
||||||
break;
|
|
||||||
}
|
}
|
||||||
else
|
|
||||||
|
NMHDR nmhdr;
|
||||||
|
nmhdr.hwndFrom = _hSelf;
|
||||||
|
nmhdr.code = NM_CLICK;
|
||||||
|
nmhdr.idFrom = reinterpret_cast<unsigned int>(this);
|
||||||
|
|
||||||
|
::SendMessage(_hParent, WM_NOTIFY, 0, reinterpret_cast<LPARAM>(&nmhdr));
|
||||||
|
|
||||||
return TRUE;
|
return TRUE;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -245,7 +245,7 @@
|
||||||
#define IDM_FORUM (IDM_ABOUT + 4)
|
#define IDM_FORUM (IDM_ABOUT + 4)
|
||||||
#define IDM_PLUGINSHOME (IDM_ABOUT + 5)
|
#define IDM_PLUGINSHOME (IDM_ABOUT + 5)
|
||||||
#define IDM_UPDATE_NPP (IDM_ABOUT + 6)
|
#define IDM_UPDATE_NPP (IDM_ABOUT + 6)
|
||||||
|
#define IDM_WIKIFAQ (IDM_ABOUT + 7)
|
||||||
|
|
||||||
|
|
||||||
#define IDM_SETTING (IDM + 8000)
|
#define IDM_SETTING (IDM + 8000)
|
||||||
|
|
|
@ -18,9 +18,9 @@
|
||||||
#ifndef RESOURCE_H
|
#ifndef RESOURCE_H
|
||||||
#define RESOURCE_H
|
#define RESOURCE_H
|
||||||
|
|
||||||
#define NOTEPAD_PLUS_VERSION "Notepad++ v4.7.2"
|
#define NOTEPAD_PLUS_VERSION "Notepad++ v4.7.3"
|
||||||
#define VERSION_VALUE "4.72\0" // should be X.Y : ie. if VERSION_DIGITALVALUE == 4, 7, 1, 0 , then X = 4, Y = 71
|
#define VERSION_VALUE "4.73\0" // should be X.Y : ie. if VERSION_DIGITALVALUE == 4, 7, 1, 0 , then X = 4, Y = 71
|
||||||
#define VERSION_DIGITALVALUE 4, 7, 2, 0
|
#define VERSION_DIGITALVALUE 4, 7, 3, 0
|
||||||
|
|
||||||
#ifndef IDC_STATIC
|
#ifndef IDC_STATIC
|
||||||
#define IDC_STATIC -1
|
#define IDC_STATIC -1
|
||||||
|
|
|
@ -255,7 +255,7 @@ int WINAPI WinMain(HINSTANCE hInstance, HINSTANCE, LPSTR lpszCmdLine, int nCmdSh
|
||||||
bool going = true;
|
bool going = true;
|
||||||
while (going)
|
while (going)
|
||||||
{
|
{
|
||||||
going = unicodeSupported?(::GetMessageW(&msg, NULL, 0, 0)):(::GetMessageA(&msg, NULL, 0, 0));
|
going = (unicodeSupported?(::GetMessageW(&msg, NULL, 0, 0)):(::GetMessageA(&msg, NULL, 0, 0))) != 0;
|
||||||
if (going)
|
if (going)
|
||||||
{
|
{
|
||||||
// if the message doesn't belong to the notepad_plus_plus's dialog
|
// if the message doesn't belong to the notepad_plus_plus's dialog
|
||||||
|
|
Loading…
Reference in New Issue