Changeset 24a5e0 for src/Views


Ignore:
Timestamp:
Feb 26, 2010, 12:40:52 PM (15 years ago)
Author:
Tillmann Crueger <crueger@…>
Branches:
Action_Thermostats, Add_AtomRandomPerturbation, Add_FitFragmentPartialChargesAction, Add_RotateAroundBondAction, Add_SelectAtomByNameAction, Added_ParseSaveFragmentResults, AddingActions_SaveParseParticleParameters, Adding_Graph_to_ChangeBondActions, Adding_MD_integration_tests, Adding_ParticleName_to_Atom, Adding_StructOpt_integration_tests, AtomFragments, Automaking_mpqc_open, AutomationFragmentation_failures, Candidate_v1.5.4, Candidate_v1.6.0, Candidate_v1.6.1, ChangeBugEmailaddress, ChangingTestPorts, ChemicalSpaceEvaluator, CombiningParticlePotentialParsing, Combining_Subpackages, Debian_Package_split, Debian_package_split_molecuildergui_only, Disabling_MemDebug, Docu_Python_wait, EmpiricalPotential_contain_HomologyGraph, EmpiricalPotential_contain_HomologyGraph_documentation, Enable_parallel_make_install, Enhance_userguide, Enhanced_StructuralOptimization, Enhanced_StructuralOptimization_continued, Example_ManyWaysToTranslateAtom, Exclude_Hydrogens_annealWithBondGraph, FitPartialCharges_GlobalError, Fix_BoundInBox_CenterInBox_MoleculeActions, Fix_ChargeSampling_PBC, Fix_ChronosMutex, Fix_FitPartialCharges, Fix_FitPotential_needs_atomicnumbers, Fix_ForceAnnealing, Fix_IndependentFragmentGrids, Fix_ParseParticles, Fix_ParseParticles_split_forward_backward_Actions, Fix_PopActions, Fix_QtFragmentList_sorted_selection, Fix_Restrictedkeyset_FragmentMolecule, Fix_StatusMsg, Fix_StepWorldTime_single_argument, Fix_Verbose_Codepatterns, Fix_fitting_potentials, Fixes, ForceAnnealing_goodresults, ForceAnnealing_oldresults, ForceAnnealing_tocheck, ForceAnnealing_with_BondGraph, ForceAnnealing_with_BondGraph_continued, ForceAnnealing_with_BondGraph_continued_betteresults, ForceAnnealing_with_BondGraph_contraction-expansion, FragmentAction_writes_AtomFragments, FragmentMolecule_checks_bonddegrees, GeometryObjects, Gui_Fixes, Gui_displays_atomic_force_velocity, ImplicitCharges, IndependentFragmentGrids, IndependentFragmentGrids_IndividualZeroInstances, IndependentFragmentGrids_IntegrationTest, IndependentFragmentGrids_Sole_NN_Calculation, JobMarket_RobustOnKillsSegFaults, JobMarket_StableWorkerPool, JobMarket_unresolvable_hostname_fix, MoreRobust_FragmentAutomation, ODR_violation_mpqc_open, PartialCharges_OrthogonalSummation, PdbParser_setsAtomName, PythonUI_with_named_parameters, QtGui_reactivate_TimeChanged_changes, Recreated_GuiChecks, Rewrite_FitPartialCharges, RotateToPrincipalAxisSystem_UndoRedo, SaturateAtoms_findBestMatching, SaturateAtoms_singleDegree, StoppableMakroAction, Subpackage_CodePatterns, Subpackage_JobMarket, Subpackage_LinearAlgebra, Subpackage_levmar, Subpackage_mpqc_open, Subpackage_vmg, Switchable_LogView, ThirdParty_MPQC_rebuilt_buildsystem, TrajectoryDependenant_MaxOrder, TremoloParser_IncreasedPrecision, TremoloParser_MultipleTimesteps, TremoloParser_setsAtomName, Ubuntu_1604_changes, stable
Children:
1f2217
Parents:
7042f45
Message:

Added -Wall flag and fixed several small hickups

Location:
src/Views
Files:
5 edited

Legend:

Unmodified
Added
Removed
  • src/Views/MethodStringView.cpp

    r7042f45 r24a5e0  
    77
    88#include "MethodStringView.hpp"
     9
     10using namespace std;
    911
    1012MethodStringView::MethodStringView(boost::function<string()> _displayMethod) :
  • src/Views/MethodStringView.hpp

    r7042f45 r24a5e0  
    1919{
    2020public:
    21   MethodStringView(boost::function<string()>);
     21  MethodStringView(boost::function<std::string()>);
    2222  virtual ~MethodStringView();
    2323
    24   virtual const string toString();
     24  virtual const std::string toString();
    2525
    2626private:
    27   boost::function<string()> displayMethod;
     27  boost::function<std::string()> displayMethod;
    2828};
    2929
  • src/Views/StreamStringView.cpp

    r7042f45 r24a5e0  
    77
    88#include <sstream>
     9#include <iostream>
    910
    1011#include "StreamStringView.hpp"
    1112
    12 StreamStringView::StreamStringView(boost::function<void(ofstream *)> _displayMethod) :
     13using namespace std;
     14
     15StreamStringView::StreamStringView(boost::function<void(ostream *)> _displayMethod) :
    1316StringView(),
    1417displayMethod(_displayMethod)
    15 {
    16   // TODO Auto-generated constructor stub
    17 
    18 }
     18{}
    1919
    2020StreamStringView::~StreamStringView()
    21 {
    22   // TODO Auto-generated destructor stub
    23 }
     21{}
    2422
    2523const string StreamStringView::toString() {
    2624  stringstream s;
    27   displayMethod((ofstream *)&s);
     25  displayMethod(dynamic_cast<ostream *>(&s));
    2826  return s.str();
    2927}
  • src/Views/StreamStringView.hpp

    r7042f45 r24a5e0  
    1010
    1111#include <boost/function.hpp>
     12#include <iostream>
    1213
    1314#include "Views/StringView.hpp"
     
    2425{
    2526public:
    26   StreamStringView(boost::function<void(ofstream *)>);
     27  StreamStringView(boost::function<void(std::ostream *)>);
    2728  virtual ~StreamStringView();
    2829
    29   virtual const string toString();
     30  virtual const std::string toString();
    3031
    3132private:
    32   boost::function<void(ofstream *)> displayMethod;
     33  boost::function<void(std::ostream *)> displayMethod;
    3334};
    3435
  • src/Views/StringView.hpp

    r7042f45 r24a5e0  
    1212#include "Views/View.hpp"
    1313
    14 using namespace std;
    15 
    1614/**
    1715 * View to show something as a string
     
    2624  virtual ~StringView();
    2725
    28   virtual const string toString()=0;
     26  virtual const std::string toString()=0;
    2927};
    3028
Note: See TracChangeset for help on using the changeset viewer.