X-Git-Url: http://git.tdb.fi/?a=blobdiff_plain;f=source%2Fpart.cpp;h=127397924f19cf5039b2fe8f1b34df780be8ed8f;hb=c8f5fd14a1fbdaaa9e1216dd5163d1f5c1b5ff27;hp=7eb19c7755f3a006bc7a81bc31d5c6841ce66361;hpb=2b70e8801c43875ed3f4135bdd0141265cff0312;p=libs%2Fgltk.git diff --git a/source/part.cpp b/source/part.cpp index 7eb19c7..1273979 100644 --- a/source/part.cpp +++ b/source/part.cpp @@ -18,7 +18,7 @@ Part::Part(const string &n): const Graphic *Part::get_graphic(State state) const { if(state>N_STATES_) - throw InvalidParameterValue("Invalid state"); + throw invalid_argument("Part::get_graphic"); return graphic[state]; } @@ -59,7 +59,7 @@ Part::Loader::~Loader() void Part::Loader::graphic(State s, const string &n) { - Graphic *grph = get_collection().get(n); + Graphic *grph = &get_collection().get(n); for(int i=0; i