* src/BufferView_pimpl.C (getStatus, dispatch): do not handle

LFUN_GOTOERROR.

	* src/bufferview_funcs.C (findInset): exit early when at end of
	document (and avoid a crash).

	* src/insets/insetbase.[Ch]: remove ERROR_CODE



git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@14706 a592a061-630c-0410-9148-cb99ea01b6c8
This commit is contained in:
Jean-Marc Lasgouttes 2006-08-16 21:06:40 +00:00
parent dd429b7f26
commit bc6cf52e9f
4 changed files with 2 additions and 8 deletions

View File

@ -910,7 +910,6 @@ FuncStatus BufferView::Pimpl::getStatus(FuncRequest const & cmd)
case LFUN_OUTLINE_DOWN:
case LFUN_OUTLINE_IN:
case LFUN_OUTLINE_OUT:
case LFUN_ERROR_NEXT:
case LFUN_NOTE_NEXT:
case LFUN_REFERENCE_NEXT:
case LFUN_WORD_FIND:
@ -1091,10 +1090,6 @@ bool BufferView::Pimpl::dispatch(FuncRequest const & cmd)
updateLabels(*buffer_);
break;
case LFUN_ERROR_NEXT:
bv_funcs::gotoInset(bv_, InsetBase::ERROR_CODE, false);
break;
case LFUN_NOTE_NEXT:
bv_funcs::gotoInset(bv_, InsetBase::NOTE_CODE, false);
break;

View File

@ -263,6 +263,8 @@ bool findInset(DocIterator & dit, vector<InsetBase_code> const & codes,
string contents;
DocIterator tmpdit = dit;
tmpdit.forwardInset();
if (!tmpdit)
return false;
if (same_content) {
InsetBase const * inset = tmpdit.nextInset();

View File

@ -78,7 +78,6 @@ TranslatorMap const build_translator()
InsetName("external", InsetBase::EXTERNAL_CODE),
InsetName("caption", InsetBase::CAPTION_CODE),
InsetName("mathmacro", InsetBase::MATHMACRO_CODE),
InsetName("error", InsetBase::ERROR_CODE),
InsetName("cite", InsetBase::CITE_CODE),
InsetName("float_list", InsetBase::FLOAT_LIST_CODE),
InsetName("index_print", InsetBase::INDEX_PRINT_CODE),

View File

@ -295,8 +295,6 @@ public:
///
MATHMACRO_CODE, // 30
///
ERROR_CODE,
///
CITE_CODE,
///
FLOAT_LIST_CODE,