Changeset 847
- Timestamp:
- 01/18/2011 01:42:37 PM (10 years ago)
- Location:
- libs/SAMGAR/trunk
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
libs/SAMGAR/trunk/GUI/server3Gui.cpp
r845 r847 168 168 NewonetoAdd=false; 169 169 170 Network::disconnect(TempConnect.GetMom()->GetRealName().c_str(),TempConnect.GetDad()->GetRealName().c_str()); 171 Network::disconnect(TempConnect.GetDad()->GetRealName().c_str(),TempConnect.GetMom()->GetRealName().c_str()); 172 /* 170 173 cmd.clear(); 171 174 cmd.addString("unsubscribe"); … … 181 184 TempConnect.GetDad()->GetRealName().c_str()); 182 185 183 } 186 */ 187 } 184 188 } 185 189 … … 746 750 { 747 751 QString filename = QFileDialog::getOpenFileName(this,"Samgar File Load", 748 QString()," .SAMstate");752 QString(),"*.SAMstate"); 749 753 QFile f( filename ); 750 754 f.open( QIODevice::ReadOnly ); … … 798 802 799 803 } 800 804 void MyConnectionView::LoadAuto(void) 805 { 806 807 808 if(QFile::exists(QString("AutoLoad.SAMstate"))) 809 { 810 this->mylogwindow->WriteToLog("Loading Autoconnect file",true); 811 QFile f(QString("AutoLoad.SAMstate")); 812 f.open( QIODevice::ReadOnly ); 813 QTextStream in(&f); 814 815 QString name; 816 817 // TODO: assume that the comment line special sighn is # and ignore all data 818 // that stands after it. 819 in.readLine(); 820 in.readLine(); 821 in.readLine(); 822 in.readLine(); 823 in.readLine();// ignore first couple of lines cos there for humans 824 825 QString Data = in.readLine(); // get first valid line 826 while(!Data.isEmpty()&&!Data.isNull()) 827 { 828 string Pdata[10];// = {" "}; 829 830 QStringList list1 = Data.split(","); 831 string name=list1.at(0).toStdString(); 832 int x = list1.at(2).toInt(); 833 int y = list1.at(3).toInt(); 834 835 for(int zz = 4;zz<list1.size();zz++) 836 { 837 Pdata[zz-4]=list1.at(zz).toStdString(); 838 } 839 AddMod(name,Pdata,x,y); 840 Data = in.readLine(); 841 } 842 in.readLine(); in.readLine();in.readLine();in.readLine(); 843 844 // load connections // put stuff here to load connections, dont worry about 845 // threads as the conns themselves should be thread safe 846 847 Data = in.readLine(); // get first valid line 848 string fake[maxports]; 849 while(!Data.isEmpty()&&!Data.isNull()) 850 { 851 QStringList list1 = Data.split(","); 852 string dname=list1.at(0).toStdString(); 853 string mname=list1.at(1).toStdString(); 854 int conntype = list1.at(2).toInt(); 855 CreateConnection(dname,mname,conntype,true,false); 856 Data = in.readLine(); 857 } 858 859 f.close(); 860 } 861 else 862 { 863 this->mylogwindow->WriteToLog("No Autoconnect file exists",false); 864 } 865 } 801 866 void MyConnectionView::updateconnection(string d,string m,bool deleate, 802 867 bool connected) -
libs/SAMGAR/trunk/INSTALL_Linux.txt
r845 r847 40 40 cp SAMGAR/GUI/*.h yarp-2.3.1/src/yarpserver/src/ 41 41 cp SAMGAR/GUI/*.qrc yarp-2.3.1/src/yarpserver/src/ 42 cp -r SAMGAR/GUI/images yarp-2.3.1/src/yarpserver/src/ 42 mkdir yarp-2.3.1/src/yarpserver/src/images 43 cp SAMGAR/GUI/images/*.* yarp-2.3.1/src/yarpserver/src/images 43 44 44 45 5. Modify CMakeList.txt file responsible for compiling yarpserver … … 53 54 54 55 FIND_PACKAGE(Qt4 COMPONENTS QtCore QtGui QtXml REQUIRED) 55 SET(QT_USE_QTXML 1)56 56 INCLUDE(${QT_USE_FILE}) 57 57
Note: See TracChangeset
for help on using the changeset viewer.