several bug-fixes

git-svn-id: https://lmms.svn.sf.net/svnroot/lmms/trunk/lmms@420 0778d3d1-df1d-0410-868b-ea421aaaa00d
This commit is contained in:
Tobias Doerffel
2006-10-30 23:18:07 +00:00
parent 45dc9cd92a
commit 0085b0aa70
7 changed files with 33 additions and 11 deletions

View File

@@ -911,7 +911,7 @@ void fileItem::determineFileType( void )
#else
QString ext = QFileInfo( fullName() ).extension( FALSE ).toLower();
#endif
if( ext == "mmp" || ext == "mpt" )
if( ext == "mmp" || ext == "mpt" || ext == "mmpz" )
{
m_type = PROJECT_FILE;
}

View File

@@ -102,7 +102,7 @@ const int PR_BOTTOM_MARGIN = SCROLLBAR_SIZE;
const int PR_TOP_MARGIN = 48;
// width of area used for resizing (the grip at the end of a note)
const int RESIZE_AREA_WIDTH = 3;
const int RESIZE_AREA_WIDTH = 4;
// width of line for setting volume/panning of note
const int NE_LINE_WIDTH = 3;
@@ -1350,8 +1350,9 @@ void pianoRoll::mousePressEvent( QMouseEvent * _me )
m_currentNote = *it;
// clicked at the "tail" of the note?
if( pos_tact_64th > m_currentNote->pos() +
m_currentNote->length() -
if( pos_tact_64th*m_ppt/64 >
( m_currentNote->pos() +
m_currentNote->length() )*m_ppt/64 -
RESIZE_AREA_WIDTH &&
m_currentNote->length() > 0 )
{
@@ -1684,8 +1685,9 @@ void pianoRoll::mouseMoveEvent( QMouseEvent * _me )
}
// cursor at the "tail" of the note?
else if( ( *it )->length() > 0 &&
pos_tact_64th > ( *it )->pos() +
( *it )->length() -
pos_tact_64th*m_ppt/64 >
( ( *it )->pos() +
( *it )->length() )*m_ppt/64 -
RESIZE_AREA_WIDTH )
{
if( QApplication::overrideCursor() )

View File

@@ -122,10 +122,10 @@ QString stringPairDrag::decodeValue( QDropEvent * _de )
{
#ifdef QT4
return( QString( _de->mimeData()->data( "lmms/stringpair"
) ).section( ':', 1, 1 ) );
) ).section( ':', 1, -1 ) );
#else
return( QString( _de->encodedData( "lmms/stringpair" ) ).section(
':', 1, 1 ) );
':', 1, -1 ) );
#endif
}

View File

@@ -488,6 +488,7 @@ void pattern::loadSettings( const QDomElement & _this )
}
ensureBeatNotes();
checkType();
/* if( _this.attribute( "frozen" ).toInt() )
{
freeze();