This commit is contained in:
parent
2f0ec2e48f
commit
33ad51327f
2 changed files with 33 additions and 20 deletions
|
@ -239,7 +239,7 @@ void CCore::SetMode(int NewMode)
|
||||||
BOOL RedrawFlag=FALSE;
|
BOOL RedrawFlag=FALSE;
|
||||||
|
|
||||||
RedrawFlag=Layer[ActiveLayer]->SetMode(NewMode);
|
RedrawFlag=Layer[ActiveLayer]->SetMode(NewMode);
|
||||||
//if (RedrawFlag) View->Invalidate();
|
|
||||||
}
|
}
|
||||||
|
|
||||||
/*****************************************************************************/
|
/*****************************************************************************/
|
||||||
|
@ -255,9 +255,12 @@ BOOL RedrawFlag=FALSE;
|
||||||
RedrawFlag=TileBank.SelectL(DownFlag);
|
RedrawFlag=TileBank.SelectL(DownFlag);
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
|
{
|
||||||
|
if (Layer[ActiveLayer]->IsVisible())
|
||||||
{
|
{
|
||||||
RedrawFlag=Layer[ActiveLayer]->LButtonControl(this,View,nFlags,CursorPos,DownFlag);
|
RedrawFlag=Layer[ActiveLayer]->LButtonControl(this,View,nFlags,CursorPos,DownFlag);
|
||||||
}
|
}
|
||||||
|
}
|
||||||
TileBank.SetActiveBrushL();
|
TileBank.SetActiveBrushL();
|
||||||
|
|
||||||
if (RedrawFlag) View->Invalidate();
|
if (RedrawFlag) View->Invalidate();
|
||||||
|
@ -282,9 +285,12 @@ BOOL RedrawFlag=FALSE;
|
||||||
RedrawFlag=TileBank.SelectR(DownFlag);
|
RedrawFlag=TileBank.SelectR(DownFlag);
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
|
{
|
||||||
|
if (Layer[ActiveLayer]->IsVisible())
|
||||||
{
|
{
|
||||||
RedrawFlag=Layer[ActiveLayer]->RButtonControl(this,View,nFlags,CursorPos,DownFlag);
|
RedrawFlag=Layer[ActiveLayer]->RButtonControl(this,View,nFlags,CursorPos,DownFlag);
|
||||||
}
|
}
|
||||||
|
}
|
||||||
TileBank.SetActiveBrushR();
|
TileBank.SetActiveBrushR();
|
||||||
|
|
||||||
if (RedrawFlag) View->Invalidate();
|
if (RedrawFlag) View->Invalidate();
|
||||||
|
@ -341,16 +347,19 @@ Vec &ThisCam=GetCam();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{ // Mouse still moved, so need to redraw windows, to get CursorPos (And pos render)
|
{
|
||||||
View->Invalidate();
|
|
||||||
if (TileViewFlag)
|
if (TileViewFlag)
|
||||||
{
|
{
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
|
{
|
||||||
|
if (Layer[ActiveLayer]->IsVisible())
|
||||||
{
|
{
|
||||||
Layer[ActiveLayer]->MouseMove(this,View,nFlags,CursorPos);
|
Layer[ActiveLayer]->MouseMove(this,View,nFlags,CursorPos);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
View->Invalidate(); // Mouse still moved, so need to redraw windows, to get CursorPos (And pos render)
|
||||||
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -401,11 +410,15 @@ CMainFrame *Frm=(CMainFrame*)AfxGetApp()->GetMainWnd();
|
||||||
CMultiBar *ParamBar=Frm->GetParamBar();
|
CMultiBar *ParamBar=Frm->GetParamBar();
|
||||||
CLayerList *List=(CLayerList*)Frm->GetDialog(IDD_LAYER_LIST_DIALOG);
|
CLayerList *List=(CLayerList*)Frm->GetDialog(IDD_LAYER_LIST_DIALOG);
|
||||||
|
|
||||||
Layer[ActiveLayer]->SetVisible(List->ListBox.GetCheck(ActiveLayer));
|
// If toggling layer, dont change the layer
|
||||||
if (ActiveLayer!=NewLayer)
|
if (List->ListBox.GetCheck(NewLayer)!=Layer[NewLayer]->IsVisible())
|
||||||
|
{
|
||||||
|
Layer[NewLayer]->SetVisible(List->ListBox.GetCheck(NewLayer));
|
||||||
|
List->ListBox.SetCurSel(ActiveLayer);
|
||||||
|
}
|
||||||
|
else
|
||||||
{
|
{
|
||||||
ActiveLayer=NewLayer;
|
ActiveLayer=NewLayer;
|
||||||
Layer[ActiveLayer]->SetVisible(List->ListBox.GetCheck(ActiveLayer));
|
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
|
@ -2,7 +2,7 @@
|
||||||
|
|
||||||
[General Info]
|
[General Info]
|
||||||
Version=1
|
Version=1
|
||||||
LastClass=CProgressDlg
|
LastClass=CLayerList
|
||||||
LastTemplate=CDialog
|
LastTemplate=CDialog
|
||||||
NewFileInclude1=#include "stdafx.h"
|
NewFileInclude1=#include "stdafx.h"
|
||||||
NewFileInclude2=#include "mapedit.h"
|
NewFileInclude2=#include "mapedit.h"
|
||||||
|
@ -18,21 +18,21 @@ Class6=CMapEditDoc
|
||||||
Class7=CMapEditView
|
Class7=CMapEditView
|
||||||
|
|
||||||
ResourceCount=11
|
ResourceCount=11
|
||||||
Resource1=IDR_MAINFRAME (English (U.S.))
|
Resource1=IDD_MAPSIZE
|
||||||
Resource2=IDR_TOOLBAR (English (U.S.))
|
Resource2=IDD_LAYERTILE_GUI
|
||||||
Resource3=IDD_MULTIBAR (English (U.S.))
|
Resource3=IDR_TOOLBAR (English (U.S.))
|
||||||
Resource4=IDD_DIALOGBAR (English (U.S.))
|
Resource4=IDD_DIALOGBAR (English (U.S.))
|
||||||
Resource5=IDD_LAYERTILE_GUI
|
Resource5=IDD_ABOUTBOX (English (U.S.))
|
||||||
Class8=CMultiBar
|
Class8=CMultiBar
|
||||||
Resource6=IDD_NEW_LAYER
|
Resource6=IDD_LAYER_LIST_DIALOG
|
||||||
Resource7=IDR_MAPEDITYPE (English (U.S.))
|
Resource7=IDR_MAPEDITYPE (English (U.S.))
|
||||||
Class9=CLayerList
|
Class9=CLayerList
|
||||||
Class10=CMapSizeDlg
|
Class10=CMapSizeDlg
|
||||||
Resource8=IDD_LAYER_LIST_DIALOG
|
Resource8=IDR_MAINFRAME (English (U.S.))
|
||||||
Class11=CGfxToolBar
|
Class11=CGfxToolBar
|
||||||
Class12=CLayerTileGUI
|
Class12=CLayerTileGUI
|
||||||
Resource9=IDD_ABOUTBOX (English (U.S.))
|
Resource9=IDD_NEW_LAYER
|
||||||
Resource10=IDD_MAPSIZE
|
Resource10=IDD_MULTIBAR (English (U.S.))
|
||||||
Class13=CNewMapGUI
|
Class13=CNewMapGUI
|
||||||
Class14=CProgressDlg
|
Class14=CProgressDlg
|
||||||
Resource11=IDD_NEWMAP
|
Resource11=IDD_NEWMAP
|
||||||
|
@ -218,7 +218,7 @@ ImplementationFile=LayerList.cpp
|
||||||
BaseClass=CDialog
|
BaseClass=CDialog
|
||||||
Filter=D
|
Filter=D
|
||||||
VirtualFilter=dWC
|
VirtualFilter=dWC
|
||||||
LastObject=CLayerList
|
LastObject=IDC_LAYER_LIST
|
||||||
|
|
||||||
[CLS:CGfxToolBar]
|
[CLS:CGfxToolBar]
|
||||||
Type=0
|
Type=0
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue