DevTools: collect JS frames only when capture stacks is enabled

BUG=363976

Review URL: https://codereview.chromium.org/252423005

git-svn-id: svn://svn.chromium.org/blink/trunk@172523 bbb929c8-8fbe-4397-9dbb-9b2b20218538