I use the \DeclareNewTOC command from the KOMA classes because it automatically produces hanging indents for the caption, same as the builtin floating environments like figure. However, unlike figure, the number of my newly defined float does not include the chapter number. The level option that is mentioned in the KOMA manual does not seem to do anything.
How can I fix it to show e.g. 1.1? Alternative solutions that produce the same result are also welcome.

\documentclass[paper=A6]{scrreprt}
\DeclareNewTOC[
float, type=floatlisting, types=floatlistings,
%level=2, % Doesn't do anything
name=Listing, listname={List of Listings}
]{lol}
\begin{document}
\chapter{Topic}
\begin{floatlisting}[h]
Foo
\caption{Some really long caption that leads to a line break.}
\end{floatlisting}
\begin{figure}[h]
Foo
\caption{Some really long caption that leads to a line break.}
\end{figure}
\end{document}
listingshas it's own implementation of captions. – Johannes_B Sep 09 '14 at 16:06[float,caption=Foo]options on thelstlistingenvironment, I can't center the code (see this question: http://tex.stackexchange.com/questions/5818/how-to-center-a-listing ). – Fritz Sep 09 '14 at 16:26