fix some compiler warnings

git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@23443 a592a061-630c-0410-9148-cb99ea01b6c8
This commit is contained in:
Jean-Marc Lasgouttes 2008-03-04 14:04:59 +00:00
parent 7d65f6931f
commit 0320d29531
4 changed files with 17 additions and 14 deletions

View File

@ -90,17 +90,20 @@ bool CmdDef::read(string const & def_file)
newCmdDefResult e = newCmdDef(name, def);
switch (e) {
case CmdDefNameEmpty:
lexrc.printError("BN_DEFINE: Command name is empty");
error = true;
break;
case CmdDefExists:
lexrc.printError("BN_DEFINE: Command `" + name + "' already defined");
error = true;
break;
case CmdDefInvalid:
lexrc.printError("BN_DEFINE: Command definition for `" + name + "' is not valid");
error = true;
case CmdDefNameEmpty:
lexrc.printError("BN_DEFINE: Command name is empty");
error = true;
break;
case CmdDefExists:
lexrc.printError("BN_DEFINE: Command `" + name + "' already defined");
error = true;
break;
case CmdDefInvalid:
lexrc.printError("BN_DEFINE: Command definition for `" + name + "' is not valid");
error = true;
break;
case CmdDefOk:
break;
}
break;

View File

@ -935,7 +935,7 @@ void Text::dispatch(Cursor & cur, FuncRequest & cmd)
pasteFromStack(cur, bv->buffer().errorList("Paste"),
convert<unsigned int>(arg));
} else {
Clipboard::GraphicsType type;
Clipboard::GraphicsType type = Clipboard::AnyGraphicsType;
if (arg == "pdf")
type = Clipboard::PdfGraphicsType;
else if (arg == "png")

View File

@ -232,7 +232,7 @@ void GuiToolbars::toggleFullScreen(bool start_full_screen)
// extracts the toolbars from the backend
ToolbarBackend::Toolbars::iterator cit = toolbarbackend.begin();
ToolbarBackend::Toolbars::iterator end = toolbarbackend.end();
int flags;
int flags = 0;
for (; cit != end; ++cit) {

View File

@ -378,7 +378,7 @@ void GuiView::closeEvent(QCloseEvent * close_event)
}
std::vector<int> const & ids = guiApp->viewIds();
for (int i = 0; i != ids.size(); ++i) {
for (size_type i = 0; i != ids.size(); ++i) {
if (id_ == ids[i])
continue;
if (guiApp->view(ids[i]).workArea(*b)) {