The Slovene lands were part of the Austro-Hungarian Empire until the latter 's dissolution at the end of World War I .