mirror of
https://git.lyx.org/repos/lyx.git
synced 2024-12-26 14:15:32 +00:00
Fix cut/copy enable r=jug ;)
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@5309 a592a061-630c-0410-9148-cb99ea01b6c8
This commit is contained in:
parent
ace20ee51b
commit
daff768455
@ -1,3 +1,7 @@
|
||||
2002-09-16 John Levon <levon@movementarian.org>
|
||||
|
||||
* lyxfunc.C: check tabular for cut/copy too
|
||||
|
||||
2002-09-12 John Levon <levon@movementarian.org>
|
||||
|
||||
* LyXAction.C: tidy
|
||||
|
@ -1,3 +1,7 @@
|
||||
2002-09-16 John Levon <levon@movementarian.org>
|
||||
|
||||
* insettabular.h: hasSelection() needs to be public
|
||||
|
||||
2002-09-12 Rob Lahaye <lahaye@snu.ac.kr>
|
||||
|
||||
* insetgraphicsParams.C: use empty string as default for rotateOrigin
|
||||
|
@ -236,6 +236,10 @@ public:
|
||||
///
|
||||
boost::signal0<void> hideDialog;
|
||||
|
||||
/// are some cells selected ?
|
||||
bool hasSelection() const {
|
||||
return has_selection;
|
||||
}
|
||||
private:
|
||||
///
|
||||
void lfunMousePress(FuncRequest const &);
|
||||
@ -285,10 +289,6 @@ private:
|
||||
///
|
||||
void removeTabularRow();
|
||||
///
|
||||
bool hasSelection() const {
|
||||
return has_selection;
|
||||
}
|
||||
///
|
||||
void clearSelection() const {
|
||||
sel_cell_start = sel_cell_end = 0;
|
||||
has_selection = false;
|
||||
|
@ -312,6 +312,13 @@ FuncStatus LyXFunc::getStatus(FuncRequest const & ev) const
|
||||
break;
|
||||
case LFUN_CUT:
|
||||
case LFUN_COPY:
|
||||
if (tli && tli->lyxCode() == Inset::TABULAR_CODE) {
|
||||
InsetTabular * t(static_cast<InsetTabular*>(tli));
|
||||
if (t->hasSelection()) {
|
||||
disable = false;
|
||||
break;
|
||||
}
|
||||
}
|
||||
disable = !mathcursor && !view()->getLyXText()->selection.set();
|
||||
break;
|
||||
#ifndef HAVE_LIBAIKSAURUS
|
||||
|
Loading…
Reference in New Issue
Block a user