Štokavian – native Serb language
Kajkavian – native Slovene Language
Since we all inhabited the same region, the languages got mixed, especially Serbian (Štokavian) became widespread because of the Great Serb Migrations towards the north.
Kajkavian, Čakavian and Štokavian are considered 'dialects' only by the Croats, because of the national political reason, speaking all three languages, Croats would be divided if the languages were called by their native names. Since the communists worked on erasing lesser ethnicities for the one big one, namely Yugoslav, they named Serbian > Štokavian, Slovenian > Kajkavian, Croatian > Čakavian after the respective words for 'what'. Serbs unlike Croats do not speak other languages (Slovenian/Kajkavian and Croatian/Čakavian), they only speak Serbian.
One of the dialects the Serbs speak is Eastern-Hercegovinian, and this dialect being the most widespread Serbian dialect of all of the Serbian language was taken as the prime standard of the literary language of Yugoslavia (SHS), also called Serbo-Croatian, with most literature (Serbian epic poetry, Dubrovnik renaissance literature etc.) written in it, it had the highest prestige. Also it is a dialect spoken in the core of the old Serbian ethnic region (the highlands), from which the most Serbs bear ancestry from.
Standard Serbo-Croatian was the Eastern-Herzegovinian dialect of the Serbian language with two reflexes of jat, the ekavian and ijekavian, now it is only called Standard Serbian (out of obvious reasons).
Why so much complexity in such a simple matter one may ask, well because of the politics as usual. Since Croats adopted a Serbian dialect (Eastern-Herzegovinian) as their literary language as well (although they had their own language Čakavian), it was unwise to tell the common Croats that they should learn to write and speak in Serbian, so they called it Štokavian. To this day 'Štokavian' or Serbian (more precisely its Eastern-Hercegovinian dialect), is the prime standard among Croats, as well as other new Yugoslav ethnicities invented in the 90's.
So in linguistic terms Slavonian's are Catholic Serbs? However i must say that national identity according to language is relatively new idea for example Americans speak English yet they regard themselves separate from English. Similar scenario in Duchy of Carniola or other duchies under Habsburg crown. Carniolan was any one living in Duchy of Carniola regardless of his native language.