Build 1645, the new "Extract Method" with "Extract to Source" checked does not bring highlighted source code along to the .cpp, instead it remains in the header.
Example:
void Class::BigFunc()
{
m_iIndex = 0; // Highlight and extract this line.
while (m_iIndex < 10)
m_iIndex++;
}
Highlighting the specified line of code and extracting to source gives this result:
//
// HEADER FILE
//
class Class
{
void ExtractedMethod()
{
m_iIndex = 0; // Highlight and extract this line.
}
}
//
// SOURCE FILE
//
void Class::ExtractedMethod()
{
}