Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
K
kicad-source-mirror
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Commits
Open sidebar
Elphel
kicad-source-mirror
Commits
1700a6a7
Commit
1700a6a7
authored
Jul 13, 2009
by
charras
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Merged dialog_load_error_base and dialog_display_info_HTML_base
parent
5156a1c1
Changes
12
Expand all
Hide whitespace changes
Inline
Side-by-side
Showing
12 changed files
with
74 additions
and
423 deletions
+74
-423
dialog_load_error.cpp
common/dialog_load_error.cpp
+29
-8
dialog_load_error.h
common/dialog_load_error.h
+0
-26
dialog_load_error_base.cpp
common/dialog_load_error_base.cpp
+0
-59
dialog_load_error_base.fbp
common/dialog_load_error_base.fbp
+0
-272
dialog_load_error_base.h
common/dialog_load_error_base.h
+0
-49
CMakeLists.txt
cvpcb/CMakeLists.txt
+2
-1
listlib.cpp
cvpcb/listlib.cpp
+5
-3
class_marker_sch.cpp
eeschema/class_marker_sch.cpp
+1
-1
eelibs_read_libraryfiles.cpp
eeschema/eelibs_read_libraryfiles.cpp
+2
-0
onrightclick.cpp
eeschema/onrightclick.cpp
+1
-1
common.h
include/common.h
+0
-3
dialog_load_error.h
include/dialog_load_error.h
+34
-0
No files found.
common/dialog_load_error.cpp
View file @
1700a6a7
...
@@ -2,12 +2,13 @@
...
@@ -2,12 +2,13 @@
DIALOG_LOAD_ERROR
::
DIALOG_LOAD_ERROR
(
wxWindow
*
parent
)
DIALOG_LOAD_ERROR
::
DIALOG_LOAD_ERROR
(
wxWindow
*
parent
)
:
:
DIALOG_
LOAD_ERROR_BASE
(
parent
)
DIALOG_
DISPLAY_HTML_TEXT_BASE
(
parent
,
wxID_ANY
,
_
(
"Load Error!"
),
wxDefaultPosition
,
wxSize
(
450
,
250
)
)
{
{
SetFocus
();
ListClear
();
}
}
void
DIALOG_LOAD_ERROR
::
On
Ok
Click
(
wxCommandEvent
&
event
)
void
DIALOG_LOAD_ERROR
::
On
CloseButton
Click
(
wxCommandEvent
&
event
)
{
{
Destroy
();
Destroy
();
}
}
...
@@ -15,18 +16,38 @@ void DIALOG_LOAD_ERROR::OnOkClick( wxCommandEvent& event )
...
@@ -15,18 +16,38 @@ void DIALOG_LOAD_ERROR::OnOkClick( wxCommandEvent& event )
void
DIALOG_LOAD_ERROR
::
ListClear
(
void
)
void
DIALOG_LOAD_ERROR
::
ListClear
(
void
)
{
{
TextCtrlList
->
Clear
(
);
m_htmlWindow
->
SetPage
(
wxEmptyString
);
}
}
/** Function ListSet
* Add a list of items.
* @param list = a pointer on a string containing items. Items are separated by '\n'
*/
void
DIALOG_LOAD_ERROR
::
ListSet
(
wxString
*
list
)
void
DIALOG_LOAD_ERROR
::
ListSet
(
wxString
*
list
)
{
{
wxString
list_value
=
*
list
;
wxArrayString
*
wxStringSplit
(
wxString
txt
,
wxChar
splitter
);
TextCtrlList
->
SetValue
(
list_value
);
wxArrayString
*
strings_list
=
wxStringSplit
(
*
list
,
wxChar
(
'\n'
)
);
m_htmlWindow
->
AppendToPage
(
wxT
(
"<ul>"
)
);
for
(
unsigned
ii
=
0
;
ii
<
strings_list
->
GetCount
();
ii
++
)
{
m_htmlWindow
->
AppendToPage
(
wxT
(
"<li>"
)
);
m_htmlWindow
->
AppendToPage
(
strings_list
->
Item
(
ii
)
);
m_htmlWindow
->
AppendToPage
(
wxT
(
"</li>"
)
);
}
m_htmlWindow
->
AppendToPage
(
wxT
(
"</ul>"
)
);
delete
strings_list
;
}
}
/** Function MessageSet
* Add a message (in bold) to message list.
* @param message = a pointer to the message
*/
void
DIALOG_LOAD_ERROR
::
MessageSet
(
wxString
*
message
)
void
DIALOG_LOAD_ERROR
::
MessageSet
(
wxString
*
message
)
{
{
wxString
message_value
=
*
message
;
wxString
message_value
;
StaticTextMessage
->
SetLabel
(
message_value
);
message_value
.
Printf
(
wxT
(
"<b>%s</b><br>"
),
message
->
GetData
()
);
m_htmlWindow
->
AppendToPage
(
message_value
);
}
}
common/dialog_load_error.h
deleted
100644 → 0
View file @
5156a1c1
#ifndef __dialog_load_error__
#define __dialog_load_error__
/**
@file
Subclass of DIALOG_LOAD_ERROR_BASE, which is generated by wxFormBuilder.
*/
#include "dialog_load_error_base.h"
/** Implementing DIALOG_LOAD_ERROR_BASE */
class
DIALOG_LOAD_ERROR
:
public
DIALOG_LOAD_ERROR_BASE
{
protected
:
// Handlers for DIALOG_LOAD_ERROR_BASE events.
void
OnOkClick
(
wxCommandEvent
&
event
);
public
:
/** Constructor */
DIALOG_LOAD_ERROR
(
wxWindow
*
parent
);
void
ListSet
(
wxString
*
list
);
void
ListClear
();
void
MessageSet
(
wxString
*
message
);
};
#endif // __dialog_load_error__
common/dialog_load_error_base.cpp
deleted
100644 → 0
View file @
5156a1c1
///////////////////////////////////////////////////////////////////////////
// C++ code generated with wxFormBuilder (version Dec 19 2008)
// http://www.wxformbuilder.org/
//
// PLEASE DO "NOT" EDIT THIS FILE!
///////////////////////////////////////////////////////////////////////////
#include "dialog_load_error_base.h"
///////////////////////////////////////////////////////////////////////////
DIALOG_LOAD_ERROR_BASE
::
DIALOG_LOAD_ERROR_BASE
(
wxWindow
*
parent
,
wxWindowID
id
,
const
wxString
&
title
,
const
wxPoint
&
pos
,
const
wxSize
&
size
,
long
style
)
:
wxDialog
(
parent
,
id
,
title
,
pos
,
size
,
style
)
{
this
->
SetSizeHints
(
wxSize
(
320
,
240
),
wxDefaultSize
);
wxBoxSizer
*
MainSizer
;
MainSizer
=
new
wxBoxSizer
(
wxVERTICAL
);
wxBoxSizer
*
MessageSizer
;
MessageSizer
=
new
wxBoxSizer
(
wxVERTICAL
);
StaticTextMessage
=
new
wxStaticText
(
this
,
wxID_ANY
,
_
(
"message dummy"
),
wxDefaultPosition
,
wxDefaultSize
,
wxALIGN_LEFT
);
StaticTextMessage
->
Wrap
(
-
1
);
MessageSizer
->
Add
(
StaticTextMessage
,
0
,
wxALIGN_LEFT
|
wxALIGN_TOP
|
wxALL
|
wxEXPAND
,
5
);
MainSizer
->
Add
(
MessageSizer
,
0
,
wxALIGN_BOTTOM
|
wxALIGN_LEFT
|
wxALIGN_RIGHT
|
wxALIGN_TOP
|
wxEXPAND
,
5
);
wxBoxSizer
*
ListSizer
;
ListSizer
=
new
wxBoxSizer
(
wxVERTICAL
);
TextCtrlList
=
new
wxTextCtrl
(
this
,
wxID_ANY
,
_
(
"list dummy"
),
wxPoint
(
0
,
0
),
wxSize
(
-
1
,
-
1
),
wxTE_DONTWRAP
|
wxTE_MULTILINE
|
wxTE_READONLY
|
wxHSCROLL
|
wxNO_BORDER
|
wxVSCROLL
);
ListSizer
->
Add
(
TextCtrlList
,
1
,
wxALIGN_BOTTOM
|
wxALIGN_CENTER_HORIZONTAL
|
wxALIGN_TOP
|
wxEXPAND
|
wxALL
,
5
);
MainSizer
->
Add
(
ListSizer
,
1
,
wxEXPAND
,
5
);
wxBoxSizer
*
bSizer5
;
bSizer5
=
new
wxBoxSizer
(
wxVERTICAL
);
OkButton
=
new
wxButton
(
this
,
wxID_ANY
,
_
(
"Ok"
),
wxDefaultPosition
,
wxDefaultSize
,
0
);
OkButton
->
SetDefault
();
bSizer5
->
Add
(
OkButton
,
0
,
wxALIGN_RIGHT
|
wxALL
,
5
);
MainSizer
->
Add
(
bSizer5
,
0
,
wxEXPAND
,
5
);
this
->
SetSizer
(
MainSizer
);
this
->
Layout
();
MainSizer
->
Fit
(
this
);
this
->
Centre
(
wxBOTH
);
// Connect Events
OkButton
->
Connect
(
wxEVT_COMMAND_BUTTON_CLICKED
,
wxCommandEventHandler
(
DIALOG_LOAD_ERROR_BASE
::
OnOkClick
),
NULL
,
this
);
}
DIALOG_LOAD_ERROR_BASE
::~
DIALOG_LOAD_ERROR_BASE
()
{
// Disconnect Events
OkButton
->
Disconnect
(
wxEVT_COMMAND_BUTTON_CLICKED
,
wxCommandEventHandler
(
DIALOG_LOAD_ERROR_BASE
::
OnOkClick
),
NULL
,
this
);
}
common/dialog_load_error_base.fbp
deleted
100644 → 0
View file @
5156a1c1
This diff is collapsed.
Click to expand it.
common/dialog_load_error_base.h
deleted
100644 → 0
View file @
5156a1c1
///////////////////////////////////////////////////////////////////////////
// C++ code generated with wxFormBuilder (version Dec 19 2008)
// http://www.wxformbuilder.org/
//
// PLEASE DO "NOT" EDIT THIS FILE!
///////////////////////////////////////////////////////////////////////////
#ifndef __dialog_load_error_base__
#define __dialog_load_error_base__
#include <wx/intl.h>
#include <wx/string.h>
#include <wx/stattext.h>
#include <wx/gdicmn.h>
#include <wx/font.h>
#include <wx/colour.h>
#include <wx/settings.h>
#include <wx/sizer.h>
#include <wx/textctrl.h>
#include <wx/button.h>
#include <wx/dialog.h>
///////////////////////////////////////////////////////////////////////////
///////////////////////////////////////////////////////////////////////////////
/// Class DIALOG_LOAD_ERROR_BASE
///////////////////////////////////////////////////////////////////////////////
class
DIALOG_LOAD_ERROR_BASE
:
public
wxDialog
{
private
:
protected
:
wxStaticText
*
StaticTextMessage
;
wxTextCtrl
*
TextCtrlList
;
wxButton
*
OkButton
;
// Virtual event handlers, overide them in your derived class
virtual
void
OnOkClick
(
wxCommandEvent
&
event
){
event
.
Skip
();
}
public
:
DIALOG_LOAD_ERROR_BASE
(
wxWindow
*
parent
,
wxWindowID
id
=
wxID_ANY
,
const
wxString
&
title
=
_
(
"Load Error!"
),
const
wxPoint
&
pos
=
wxDefaultPosition
,
const
wxSize
&
size
=
wxDefaultSize
,
long
style
=
wxCLOSE_BOX
|
wxDEFAULT_DIALOG_STYLE
|
wxMAXIMIZE_BOX
|
wxRESIZE_BORDER
);
~
DIALOG_LOAD_ERROR_BASE
();
};
#endif //__dialog_load_error_base__
cvpcb/CMakeLists.txt
View file @
1700a6a7
...
@@ -4,7 +4,8 @@ include_directories(${CMAKE_CURRENT_SOURCE_DIR}
...
@@ -4,7 +4,8 @@ include_directories(${CMAKE_CURRENT_SOURCE_DIR}
${
Boost_INCLUDE_DIR
}
${
Boost_INCLUDE_DIR
}
../3d-viewer
../3d-viewer
../pcbnew
../pcbnew
../polygon
)
../polygon
${
CMAKE_SOURCE_DIR
}
/common
)
set
(
CVPCB_SRCS
set
(
CVPCB_SRCS
autosel.cpp
autosel.cpp
...
...
cvpcb/listlib.cpp
View file @
1700a6a7
...
@@ -19,7 +19,9 @@
...
@@ -19,7 +19,9 @@
#include "cvpcb.h"
#include "cvpcb.h"
#include "protos.h"
#include "protos.h"
/* MDC file strings */
#include "dialog_load_error.h"
/* MDC file strings */
wxString
mdc_files_not_found
;
wxString
mdc_files_not_found
;
wxString
mdc_files_invalid
;
wxString
mdc_files_invalid
;
...
@@ -54,7 +56,7 @@ bool LoadFootprintFiles( const wxArrayString& libNames,
...
@@ -54,7 +56,7 @@ bool LoadFootprintFiles( const wxArrayString& libNames,
if
(
!
list
.
empty
()
)
if
(
!
list
.
empty
()
)
list
.
clear
();
list
.
clear
();
/* Check if there are footprint libraries in project file */
/* Check if there are footprint libraries in project file */
if
(
libNames
.
GetCount
()
==
0
)
if
(
libNames
.
GetCount
()
==
0
)
{
{
wxMessageBox
(
_
(
"No PCB foot print libraries are listed in the current project file."
),
wxMessageBox
(
_
(
"No PCB foot print libraries are listed in the current project file."
),
...
@@ -169,7 +171,7 @@ bool LoadFootprintFiles( const wxArrayString& libNames,
...
@@ -169,7 +171,7 @@ bool LoadFootprintFiles( const wxArrayString& libNames,
}
}
/**
/**
* Routine de lecture du fichier Doc associe a la librairie ModLibName.
* Routine de lecture du fichier Doc associe a la librairie ModLibName.
* Cree en memoire la chaine liste des docs pointee par MList
* Cree en memoire la chaine liste des docs pointee par MList
* ModLibName = full file Name de la librairie Modules
* ModLibName = full file Name de la librairie Modules
...
...
eeschema/class_marker_sch.cpp
View file @
1700a6a7
...
@@ -138,7 +138,7 @@ void MARKER_SCH::DisplayMarkerInfo( WinEDA_SchematicFrame* aFrame )
...
@@ -138,7 +138,7 @@ void MARKER_SCH::DisplayMarkerInfo( WinEDA_SchematicFrame* aFrame )
{
{
wxString
msg
=
GetReporter
().
ShowHtml
();
wxString
msg
=
GetReporter
().
ShowHtml
();
DIALOG_DISPLAY_HTML_TEXT_BASE
infodisplay
(
aFrame
,
-
1
,
wxEmptyString
,
DIALOG_DISPLAY_HTML_TEXT_BASE
infodisplay
(
aFrame
,
-
1
,
_
(
"Marker Info"
)
,
wxGetMousePosition
(),
wxSize
(
550
,
140
)
);
wxGetMousePosition
(),
wxSize
(
550
,
140
)
);
infodisplay
.
m_htmlWindow
->
SetPage
(
msg
);
infodisplay
.
m_htmlWindow
->
SetPage
(
msg
);
...
...
eeschema/eelibs_read_libraryfiles.cpp
View file @
1700a6a7
...
@@ -18,6 +18,8 @@
...
@@ -18,6 +18,8 @@
#include "general.h"
#include "general.h"
#include "protos.h"
#include "protos.h"
#include "dialog_load_error.h"
/* Local Functions */
/* Local Functions */
static
LibEDA_BaseStruct
*
ReadDrawEntryItemDescription
(
EDA_LibComponentStruct
*
aParent
,
FILE
*
f
,
static
LibEDA_BaseStruct
*
ReadDrawEntryItemDescription
(
EDA_LibComponentStruct
*
aParent
,
FILE
*
f
,
char
*
Line
,
int
*
LineNum
);
char
*
Line
,
int
*
LineNum
);
...
...
eeschema/onrightclick.cpp
View file @
1700a6a7
...
@@ -640,5 +640,5 @@ void AddMenusForMarkers( wxMenu* aPopMenu, MARKER_SCH* aMarker,
...
@@ -640,5 +640,5 @@ void AddMenusForMarkers( wxMenu* aPopMenu, MARKER_SCH* aMarker,
/**********************************************************************/
/**********************************************************************/
{
{
ADD_MENUITEM
(
aPopMenu
,
ID_POPUP_SCH_DELETE
,
_
(
"Delete Marker"
),
delete_xpm
);
ADD_MENUITEM
(
aPopMenu
,
ID_POPUP_SCH_DELETE
,
_
(
"Delete Marker"
),
delete_xpm
);
ADD_MENUITEM
(
aPopMenu
,
ID_POPUP_SCH_GETINFO_MARKER
,
_
(
"
About this Marker
"
),
info_xpm
);
ADD_MENUITEM
(
aPopMenu
,
ID_POPUP_SCH_GETINFO_MARKER
,
_
(
"
Marker Error Info
"
),
info_xpm
);
}
}
include/common.h
View file @
1700a6a7
...
@@ -9,9 +9,6 @@
...
@@ -9,9 +9,6 @@
#include "wx/confbase.h"
#include "wx/confbase.h"
#include "wx/fileconf.h"
#include "wx/fileconf.h"
/* TODO how do i else need to include a common dialog ? */
#include "../common/dialog_load_error.h"
class
wxAboutDialogInfo
;
class
wxAboutDialogInfo
;
class
BASE_SCREEN
;
class
BASE_SCREEN
;
class
WinEDA_DrawFrame
;
class
WinEDA_DrawFrame
;
...
...
include/dialog_load_error.h
0 → 100644
View file @
1700a6a7
#ifndef __dialog_load_error_h_
#define __dialog_load_error_h_
/**
@file
Subclass of DIALOG_DISPLAY_HTML_TEXT_BASE, which is generated by wxFormBuilder.
*/
#include "dialog_display_info_HTML_base.h"
/** Implementing DIALOG_LOAD_ERROR */
class
DIALOG_LOAD_ERROR
:
public
DIALOG_DISPLAY_HTML_TEXT_BASE
{
protected
:
// Handlers for DIALOG_LOAD_ERROR_BASE events.
void
OnCloseButtonClick
(
wxCommandEvent
&
event
);
public
:
/** Constructor */
DIALOG_LOAD_ERROR
(
wxWindow
*
parent
);
/** Function ListSet
* Add a list of items.
* @param list = a pointer on a string containing items. Items are separated by '\n'
*/
void
ListSet
(
wxString
*
list
);
void
ListClear
();
/** Function MessageSet
* Add a message (in bold) to message list.
* @param message = a pointer to the message
*/
void
MessageSet
(
wxString
*
message
);
};
#endif // __dialog_load_error_h_
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment