Are we sure that Home Depot has already paid for the items sitting on the shelves? I've seen them do so many returns by marking things Return To Vendor. Margins these days seem to be based around branding/design/quality control rather than sunk production cost, and I'd imagine that retail stores have optimized things so that they aren't assuming the full wholesale-cost risk of theft/damage/clearance.
Depends on how long the item has been sitting on that shelf. They usually factor their invoices to attract suppliers, so they pay their factoring bank a few weeks after the item has been received.