[dia] typo / warning roundup
- From: Zander <zbrown src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [dia] typo / warning roundup
- Date: Sat, 25 May 2019 12:45:59 +0000 (UTC)
commit 5cb4adf2d2c5d801e040d50d87ed708788ddcb6d
Author: Zander Brown <zbrown gnome org>
Date: Sat May 25 13:45:31 2019 +0100
typo / warning roundup
app/sheets_dialog_callbacks.c | 2 +-
plug-ins/layout/dia-graph.cpp | 7 ++++---
plug-ins/wmf/wmf.cpp | 7 +++++--
sheets/Jackson.sheet | 6 +++---
sheets/Lights.sheet | 4 ++--
5 files changed, 15 insertions(+), 11 deletions(-)
---
diff --git a/app/sheets_dialog_callbacks.c b/app/sheets_dialog_callbacks.c
index 06397d2f..5492f262 100644
--- a/app/sheets_dialog_callbacks.c
+++ b/app/sheets_dialog_callbacks.c
@@ -1807,13 +1807,13 @@ on_sheets_dialog_button_apply_clicked (GtkButton *button,
SheetMod *sm;
GSList *sheets_list;
GSList *find_list;
+ Sheet *new_sheet = NULL;
sm = iter_list->data;
switch (sm->mod)
{
GSList *sheet_object_mods_list;
GSList *list;
- Sheet *new_sheet = NULL;
case SHEETMOD_MOD_NEW:
write_user_sheet(&sm->sheet);
diff --git a/plug-ins/layout/dia-graph.cpp b/plug-ins/layout/dia-graph.cpp
index 99cb4f27..b33fb967 100644
--- a/plug-ins/layout/dia-graph.cpp
+++ b/plug-ins/layout/dia-graph.cpp
@@ -74,6 +74,7 @@ public :
eResult Layout (const char *module);
bool GetNodePosition (int node, double* x, double* y);
int GetEdgeBends (int e, double *coords, int len);
+ virtual ~DiaGraph();
protected :
bool Scale (double xfactor, double yfactor);
private :
@@ -137,7 +138,7 @@ DiaGraph::Layout (const char *module)
bool
DiaGraph::GetNodePosition (int node, double* x, double* y)
{
- if (node >= 0 && node < m_nodes.size()) {
+ if (node >= 0 && ((size_t) node) < m_nodes.size()) {
Node &n = m_nodes[node];
if (x)
*x = n.center.x - n.width / 2;
@@ -151,11 +152,11 @@ DiaGraph::GetNodePosition (int node, double* x, double* y)
int
DiaGraph::GetEdgeBends (int e, double *coords, int len)
{
- if (e >= m_edges.size() || e < 0)
+ if (((size_t) e) >= m_edges.size() || e < 0)
return 0;
Edge &edge = m_edges[e];
if (coords && len > 0) {
- for (int i = 0, j = 0; i < len && j < edge.size(); i+=2, ++j) {
+ for (size_t i = 0, j = 0; i < ((size_t) len) && j < edge.size(); i+=2, ++j) {
coords[i ] = edge[j].x;
coords[i+1] = edge[j].y;
}
diff --git a/plug-ins/wmf/wmf.cpp b/plug-ins/wmf/wmf.cpp
index a6bac4f8..575b2f8f 100644
--- a/plug-ins/wmf/wmf.cpp
+++ b/plug-ins/wmf/wmf.cpp
@@ -72,9 +72,10 @@ wmf.cpp:1383:40: error: cast from 'void*' to 'W32::HDC' loses precision
# define DIRECT_WMF
#endif
+#ifdef G_OS_WIN32
/* force linking with gdi32 */
#pragma comment( lib, "gdi32" )
-
+#endif
// #define DIRECT_WMF
@@ -241,6 +242,7 @@ static void _nada(WmfRenderer*, const char*, ...) { }
#else
# define DIAG_NOTE my_log
#endif
+#ifdef G_OS_WIN32
static void
my_log(WmfRenderer* renderer, const char* format, ...)
{
@@ -258,6 +260,7 @@ my_log(WmfRenderer* renderer, const char* format, ...)
g_free(string);
}
+#endif
/*
* renderer interface implementation
@@ -1294,6 +1297,7 @@ wmf_renderer_class_init (WmfRendererClass *klass)
renderer_class->is_capable_to = is_capable_to;
}
+#ifdef G_OS_WIN32
/* plug-in export api */
static gboolean
export_data(DiagramData *data, DiaContext *ctx,
@@ -1445,7 +1449,6 @@ export_data(DiagramData *data, DiaContext *ctx,
return TRUE;
}
-#ifdef G_OS_WIN32
static const gchar *wmf_extensions[] = { "wmf", NULL };
static DiaExportFilter wmf_export_filter = {
N_("Windows Metafile"),
diff --git a/sheets/Jackson.sheet b/sheets/Jackson.sheet
index 0ed2d684..1a9f2fcc 100644
--- a/sheets/Jackson.sheet
+++ b/sheets/Jackson.sheet
@@ -8,11 +8,11 @@
</object>
<object name="Jackson - domain" intdata="2">
<description>A Jackson designed domain</description>
- <icon>res:/org/gnome/Dia/Jackson/designeddomain.png</icon>
+ <icon>res:/org/gnome/Dia/Jackson/designed_domain.png</icon>
</object>
<object name="Jackson - domain" intdata="3">
<description>A Jackson machine domain</description>
- <icon>res:/org/gnome/Dia/Jackson/machinedomain.png</icon>
+ <icon>res:/org/gnome/Dia/Jackson/machine_domain.png</icon>
</object>
<object name="Jackson - requirement" intdata="1">
<description>A Jackson requirement</description>
@@ -22,7 +22,7 @@
</object>
<object name="Jackson - phenomenon" intdata="2">
<description>A Jackson requirement phenomenon</description>
- <icon>res:/org/gnome/Dia/Jackson/reqphen.png</icon>
+ <icon>res:/org/gnome/Dia/Jackson/req_phen.png</icon>
</object>
</contents>
</sheet>
diff --git a/sheets/Lights.sheet b/sheets/Lights.sheet
index 18682bcc..320b0dfc 100644
--- a/sheets/Lights.sheet
+++ b/sheets/Lights.sheet
@@ -6,7 +6,7 @@
<object name="Lights - PAR">
<description>PAR</description>
</object>
- <object name="Lights - PARfloor">
+ <object name="Lights - PAR_floor">
<description>PAR on the floor</description>
</object>
<object name="Lights - ACL">
@@ -34,7 +34,7 @@
<object name="Lights - Stroboscope">
<description>Stroboscope light</description>
</object>
- <object name="Lights - Movinghead">
+ <object name="Lights - Moving_head">
<description>Moving head</description>
</object>
<object name="Lights - Scanner">
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]