rotate_left = new QPushButton(this, \ rotate_left->setGeometry( QRect(178, 18, 39, 39) );
rotate_left->setPixmap( QPixmap::fromMimeSource( \ rotate_left->hide();
rotate_right = new QPushButton(this, \ rotate_right->setGeometry( QRect(261, 18, 39, 39) );
rotate_right->setPixmap( QPixmap::fromMimeSource( \ rotate_right->hide();
shrink = new QPushButton(this, \
shrink->setGeometry( QRect(345, 18, 39, 39) );
shrink->setPixmap( QPixmap::fromMimeSource( \ shrink->hide();
preImage = new QPushButton(this, \ preImage->setGeometry( QRect(96, 220, 39, 38) );
preImage->setPixmap( QPixmap::fromMimeSource( \ preImage->hide();
nextImage = new QPushButton(this, \ nextImage->setGeometry( QRect(345, 220, 39, 38) );
nextImage->setPixmap( QPixmap::fromMimeSource( \ nextImage->hide();
autoplay = new QPushButton(this, \
autoplay->setGeometry( QRect(220, 220, 39, 38) );
autoplay->setPixmap( QPixmap::fromMimeSource( \ autoplay->hide();
back = new QPushButton( this, \
back->setGeometry( QRect( 433, 220, 38, 38 ) );
back->setPixmap( QPixmap::fromMimeSource( \ back->hide();
showMenu = new QIconView(this, \ showMenu->setGeometry(0, 224, 480, 50); showMenu->hide();
Dt = new DateAndTime(this, 0, Qt::WStyle_Customize |Qt::WStyle_NoBorder); Dt->setGeometry(360,0,120,80); Dt->hide();
/*菜单内容*/
menuFlag = 0; timeFlag = 0; zoomLevel = 0;
邢台学院信息科学与技术系嵌入式课程设计
image_x = 0; image_y = 0; image_w = 0; image_h = 0;
move_image_x = 0; move_image_y = 0; clickFlag = 0; #ifndef DEBUG_ON_PC fb = 0;
fb_mem = NULL; #endif
QIconViewItem *tmpItem;
tmpItem = new QIconViewItem(showMenu,\ tmpItem = new QIconViewItem(showMenu,\ tmpItem = new QIconViewItem(showMenu,\ tmpItem = new QIconViewItem(showMenu,\ tmpItem = new QIconViewItem(showMenu,\ tmpItem = new QIconViewItem(showMenu,\ tmpItem = new QIconViewItem(showMenu,\ tmpItem = new QIconViewItem(showMenu,\ tmpItem = new QIconViewItem(showMenu,\ tmpItem = new QIconViewItem(showMenu,\ tmpItem = new QIconViewItem(showMenu,\ tmpItem = new QIconViewItem(showMenu,\ tmpItem = new QIconViewItem(showMenu,\ /*菜单内容*/
connect(showMenu,SIGNAL( doubleClicked(QIconViewItem*) ), this, SLOT(onMenuItemClick(QIconViewItem*)));
connect(enlarge,SIGNAL( clicked() ), this, SLOT(onEnlarge()));
connect(rotate_left,SIGNAL( clicked() ), this, SLOT(onRotate_Left())); connect(rotate_right,SIGNAL( clicked() ), this, SLOT(onRotate_Right())); connect(shrink,SIGNAL( clicked() ), this, SLOT(onShrink()));
connect(preImage,SIGNAL( clicked() ), this, SLOT(onpreImage())); connect(nextImage,SIGNAL( clicked() ), this, SLOT(onnextImage())); connect(autoplay,SIGNAL( clicked() ), this, SLOT(onautoplay())); connect( back, SIGNAL( clicked() ), this, SLOT( onBack() ) ); }
showPhoto::~showPhoto() { }
void showPhoto::languageChange() {
setCaption( tr( \}
showMusic.cpp
#include \#include
#include
#include \
ShowMusic::ShowMusic( QWidget* parent, const char* name, bool modal, WFlags fl ) : Window( parent, name, modal, fl ) {
if ( !name )
setName( \
setMinimumSize( QSize( 480, 272 ) ); setMaximumSize( QSize( 480, 272 ) );
setPaletteBackgroundPixmap( QPixmap::fromMimeSource( \
playName = new QLabel( this, \ playName->setGeometry( QRect( 0, 0, 400, 20 ) );
playName->setPaletteForegroundColor(QColor(255, 255, 255));
playScreen = new QLabel( this, \
playScreen->setGeometry( QRect( 40, 20, 400, 170 ) );
playScreen->setPaletteBackgroundColor( QColor( 220, 235, 255 ) );
playScreen->setPaletteBackgroundPixmap(QPixmap::fromMimeSource(\ playScreen->hide();
progress = new QSlider(this, \
progress->setGeometry( QRect( 40, 190, 320, 15 ) );
progress->setPaletteBackgroundColor( QColor( 42, 42, 42 ) ); progress->setMaxValue(100);
progress->setOrientation(QSlider::Horizontal);
sound_button = new QPushButton(this, \ sound_button->setGeometry(QRect(360, 190, 20, 15));
sound_button->setPixmap(QPixmap::fromMimeSource(\ sound_button->setPaletteBackgroundColor( QColor( 220, 235, 255 ) );
邢台学院信息科学与技术系嵌入式课程设计
sound_slider = new QSlider(this, \ sound_slider->setGeometry(QRect(380, 190, 60, 15));
sound_slider->setPaletteBackgroundColor( QColor( 42, 42, 42 ) ); sound_slider->setMaxValue(35); sound_slider->setValue(25);
sound_slider->setOrientation(QSlider::Horizontal);
back = new QPushButton( this, \
back->setGeometry( QRect( 423, 222, 39, 39 ) );
back->setPaletteBackgroundColor( QColor( 225, 230, 170 ) );
back->setPixmap( QPixmap::fromMimeSource( \
next = new QPushButton( this, \
next->setGeometry( QRect( 336, 222, 39, 39 ) );
next->setPaletteBackgroundColor( QColor( 225, 230, 170 ) );
next->setPixmap( QPixmap::fromMimeSource( \
play = new QPushButton( this, \
play->setGeometry( QRect( 220, 222, 39, 39 ) );
play->setPaletteBackgroundColor( QColor( 225, 230, 170 ) );
play->setPixmap( QPixmap::fromMimeSource( \
pre = new QPushButton( this, \
pre->setGeometry( QRect( 106, 222, 39, 39 ) );
pre->setPaletteBackgroundColor( QColor( 225, 230, 170 ) );
pre->setPixmap( QPixmap::fromMimeSource( \
List = new QPushButton( this, \
List->setGeometry( QRect( 16, 222, 39, 39 ) );
List->setPaletteBackgroundColor( QColor( 225, 230, 170 ) );
List->setPixmap( QPixmap::fromMimeSource( \
playtimer = new QTimer(this); playtimer->start(50); play->setFocus(); procFlag = 0; playFlag = 0; soundFlag = 1; languageChange();
resize( QSize(480, 272).expandedTo(minimumSizeHint()) ); clearWState( WState_Polished ); // signals and slots connections[7]
connect( play, SIGNAL( clicked() ), this, SLOT( onPlay() ) ); connect( pre, SIGNAL( clicked() ), this, SLOT( onPre() ) ); connect( next, SIGNAL( clicked() ), this, SLOT( onNext() ) ); connect( List, SIGNAL( clicked() ), this, SLOT( onList() ) );
connect( back, SIGNAL( clicked() ), this, SLOT( onBack() ) );
connect( playtimer, SIGNAL(timeout()), this, SLOT(update_Progress()));
connect( progress, SIGNAL(valueChanged(int)), this, SLOT(setProgress()));
connect( sound_button, SIGNAL(clicked()), this, SLOT(onSound_Button()));
connect( sound_slider, SIGNAL(sliderMoved(int)), this, SLOT(sound_Change())); ShowMusic::~ShowMusic() { }
void ShowMusic::languageChange() {
setCaption( tr( \
playScreen->setText( tr( \ playName->setText( tr( \}
welcome.cpp
#include \#include
#include
#include \[8]
Welcome::Welcome( QWidget* parent, const char* name, bool modal, WFlags fl ) : Window( parent, name, modal, fl ) {
if ( !name )
setName( \
setMinimumSize( QSize( 480, 272 ) );
setMaximumSize( QSize( 480, 272 ) );
setPaletteBackgroundPixmap( QPixmap::fromMimeSource( \
photoButton = new QPushButton( this, \ photoButton->setGeometry( QRect( 68, 110, 59, 59 ) );
photoButton->setPixmap(QPixmap::fromMimeSource(\
musicButton = new QPushButton( this, \ musicButton->setGeometry( QRect( 205, 110, 59, 59 ) );
百度搜索“77cn”或“免费范文网”即可找到本站免费阅读全部范文。收藏本站方便下次阅读,免费范文网,提供经典小说综合文库数码相框设计与实现 - 图文(5)在线全文阅读。
相关推荐: